更新
This commit is contained in:
@@ -55,12 +55,12 @@ class DeviceInfoWidget extends GetView {
|
||||
Text(
|
||||
deviceListController.model.deviceList[index]['name'] ??
|
||||
'SWES系列 01号智能一键入眠床',
|
||||
style: FlutterFlowTheme.of(context).bodyMedium.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: Colors.white,
|
||||
fontSize: 30.rpx,
|
||||
letterSpacing: 0,
|
||||
),
|
||||
style: TextStyle(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: Colors.white,
|
||||
fontSize: 30.rpx,
|
||||
letterSpacing: 0,
|
||||
),
|
||||
maxLines: 1, // 限制显示一行
|
||||
overflow: TextOverflow.ellipsis, // 超出部分显示省略号
|
||||
),
|
||||
@@ -108,40 +108,31 @@ class DeviceInfoWidget extends GetView {
|
||||
.deviceList[
|
||||
index]['_id'] ??
|
||||
''),
|
||||
style: FlutterFlowTheme.of(
|
||||
context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily:
|
||||
'Readex Pro',
|
||||
color:
|
||||
Color(0xFFC8CBD2),
|
||||
fontSize: 26.rpx,
|
||||
letterSpacing: 0,
|
||||
lineHeight: 1),
|
||||
style: TextStyle(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: Color(0xFFC8CBD2),
|
||||
fontSize: 26.rpx,
|
||||
letterSpacing: 0,
|
||||
height: 1),
|
||||
),
|
||||
TextSpan(
|
||||
text:
|
||||
' (${deviceListController.model.deviceList[index]['status'] ?? ''})',
|
||||
style:
|
||||
FlutterFlowTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily:
|
||||
'Readex Pro',
|
||||
color: deviceListController
|
||||
.model
|
||||
.deviceList[index]
|
||||
[
|
||||
'status'] ==
|
||||
'在线'
|
||||
? Color(
|
||||
0xFF07C160) // 在线的颜色
|
||||
: Color(
|
||||
0xFFEA7CA7), // 离线的颜色
|
||||
fontSize: 26.rpx,
|
||||
letterSpacing: 0,
|
||||
),
|
||||
style: TextStyle(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: deviceListController
|
||||
.model
|
||||
.deviceList[
|
||||
index]
|
||||
['status'] ==
|
||||
'在线'
|
||||
? Color(
|
||||
0xFF07C160) // 在线的颜色
|
||||
: Color(
|
||||
0xFFEA7CA7), // 离线的颜色
|
||||
fontSize: 26.rpx,
|
||||
letterSpacing: 0,
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
@@ -160,14 +151,12 @@ class DeviceInfoWidget extends GetView {
|
||||
.model.deviceList[index]
|
||||
['roomName'] ??
|
||||
''),
|
||||
style: FlutterFlowTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: Color(0xFFC8CBD2),
|
||||
fontSize: 26.rpx,
|
||||
letterSpacing: 0,
|
||||
lineHeight: 1),
|
||||
style: TextStyle(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: Color(0xFFC8CBD2),
|
||||
fontSize: 26.rpx,
|
||||
letterSpacing: 0,
|
||||
height: 1),
|
||||
),
|
||||
),
|
||||
Align(
|
||||
@@ -180,14 +169,12 @@ class DeviceInfoWidget extends GetView {
|
||||
?["status"]
|
||||
?.toString() ??
|
||||
''),
|
||||
style: FlutterFlowTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: Color(0xFFC8CBD2),
|
||||
fontSize: 26.rpx,
|
||||
letterSpacing: 0,
|
||||
lineHeight: 1),
|
||||
style: TextStyle(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: Color(0xFFC8CBD2),
|
||||
fontSize: 26.rpx,
|
||||
letterSpacing: 0,
|
||||
height: 1),
|
||||
),
|
||||
)
|
||||
].divide(SizedBox(height: 36.rpx)),
|
||||
@@ -207,14 +194,12 @@ class DeviceInfoWidget extends GetView {
|
||||
text: '控制',
|
||||
options: FFButtonOptions(
|
||||
color: Color(0XFF85F5FF),
|
||||
textStyle: FlutterFlowTheme.of(context)
|
||||
.titleSmall
|
||||
.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: Colors.white,
|
||||
fontSize: 28.rpx,
|
||||
letterSpacing: 0,
|
||||
),
|
||||
textStyle: TextStyle(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: Colors.white,
|
||||
fontSize: 28.rpx,
|
||||
letterSpacing: 0,
|
||||
),
|
||||
elevation: 0,
|
||||
borderSide: BorderSide(
|
||||
color: Colors.transparent,
|
||||
@@ -282,15 +267,13 @@ class DeviceInfoWidget extends GetView {
|
||||
if (device['bind_type'] == 1)
|
||||
Text(
|
||||
'已分享:',
|
||||
style: FlutterFlowTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
fontSize: AppFontsize
|
||||
.normal_text_size,
|
||||
letterSpacing: 0,
|
||||
color: Colors.white,
|
||||
),
|
||||
style: TextStyle(
|
||||
fontFamily: 'Readex Pro',
|
||||
fontSize:
|
||||
AppFontsize.normal_text_size,
|
||||
letterSpacing: 0,
|
||||
color: Colors.white,
|
||||
),
|
||||
),
|
||||
if (device['bind_type'] == 1)
|
||||
Padding(
|
||||
@@ -303,42 +286,36 @@ class DeviceInfoWidget extends GetView {
|
||||
['shareNum'] ??
|
||||
0)
|
||||
.toString(),
|
||||
style: FlutterFlowTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: Color(0xFF85F5FF),
|
||||
fontSize: AppFontsize
|
||||
.normal_text_size,
|
||||
letterSpacing: 0,
|
||||
),
|
||||
style: TextStyle(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: Color(0xFF85F5FF),
|
||||
fontSize:
|
||||
AppFontsize.normal_text_size,
|
||||
letterSpacing: 0,
|
||||
),
|
||||
),
|
||||
),
|
||||
if (device['bind_type'] == 1)
|
||||
Text(
|
||||
'人',
|
||||
style: FlutterFlowTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
fontSize: AppFontsize
|
||||
.normal_text_size,
|
||||
letterSpacing: 0,
|
||||
color: Colors.white,
|
||||
),
|
||||
style: TextStyle(
|
||||
fontFamily: 'Readex Pro',
|
||||
fontSize:
|
||||
AppFontsize.normal_text_size,
|
||||
letterSpacing: 0,
|
||||
color: Colors.white,
|
||||
),
|
||||
),
|
||||
if (device['bind_type'] == 2)
|
||||
Text(
|
||||
'来自',
|
||||
style: FlutterFlowTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
fontSize: AppFontsize
|
||||
.normal_text_size,
|
||||
letterSpacing: 0,
|
||||
color: Colors.white,
|
||||
),
|
||||
style: TextStyle(
|
||||
fontFamily: 'Readex Pro',
|
||||
fontSize:
|
||||
AppFontsize.normal_text_size,
|
||||
letterSpacing: 0,
|
||||
color: Colors.white,
|
||||
),
|
||||
),
|
||||
if (device['bind_type'] == 2)
|
||||
Padding(
|
||||
@@ -347,28 +324,24 @@ class DeviceInfoWidget extends GetView {
|
||||
5, 0, 5, 0),
|
||||
child: Text(
|
||||
'${device['suname']?.length > 5 ? device['suname'].substring(0, 5) + '...' : device['suname']}',
|
||||
style: FlutterFlowTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: Color(0xFF85F5FF),
|
||||
fontSize: AppFontsize
|
||||
.normal_text_size,
|
||||
letterSpacing: 0,
|
||||
),
|
||||
style: TextStyle(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: Color(0xFF85F5FF),
|
||||
fontSize:
|
||||
AppFontsize.normal_text_size,
|
||||
letterSpacing: 0,
|
||||
),
|
||||
),
|
||||
),
|
||||
if (device['bind_type'] == 2)
|
||||
Text(
|
||||
'的分享',
|
||||
style: FlutterFlowTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
fontSize: 21.rpx,
|
||||
letterSpacing: 0,
|
||||
color: Colors.white,
|
||||
),
|
||||
style: TextStyle(
|
||||
fontFamily: 'Readex Pro',
|
||||
fontSize: 21.rpx,
|
||||
letterSpacing: 0,
|
||||
color: Colors.white,
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
@@ -407,14 +380,12 @@ class DeviceInfoWidget extends GetView {
|
||||
SizedBox(width: 5),
|
||||
Text(
|
||||
'睡眠报告',
|
||||
style: FlutterFlowTheme.of(context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: Colors.white,
|
||||
fontSize: 21.rpx,
|
||||
letterSpacing: 0,
|
||||
),
|
||||
style: TextStyle(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: Colors.white,
|
||||
fontSize: 21.rpx,
|
||||
letterSpacing: 0,
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
|
||||
Reference in New Issue
Block a user