Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
laki_icu_app
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
张宏
laki_icu_app
Commits
6106b9fe
Commit
6106b9fe
authored
Jun 23, 2026
by
akari
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
http://git.ruanyiit.com/zhanghong/laki_icu_app
parents
14b0b287
a30f8dc0
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
9 deletions
+20
-9
monitoring_alert_card.dart
...views/monitoring/index/widgets/monitoring_alert_card.dart
+20
-9
No files found.
lib/views/monitoring/index/widgets/monitoring_alert_card.dart
View file @
6106b9fe
...
...
@@ -12,15 +12,15 @@ class MonitoringAlertCard extends StatelessWidget {
@override
Widget
build
(
BuildContext
context
)
{
final
has
Pending
=
alerts
.
any
((
item
)
=>
item
.
status
.
contains
(
'待处理'
));
final
has
Empty
=
alerts
.
isEmpty
;
//
alerts.any((item) => item.status.contains('待处理'));
return
Container
(
padding:
EdgeInsets
.
symmetric
(
horizontal:
35
.
w
,
vertical:
30
.
h
),
decoration:
BoxDecoration
(
image:
DecorationImage
(
image:
AssetImage
(
has
Pending
?
'lib/assets/monitoring/alert_box_bg_
2
.png'
:
'lib/assets/monitoring/alert_box_bg_
1
.png'
,
has
Empty
?
'lib/assets/monitoring/alert_box_bg_
1
.png'
:
'lib/assets/monitoring/alert_box_bg_
2
.png'
,
),
fit:
BoxFit
.
fill
,
),
...
...
@@ -38,7 +38,7 @@ class MonitoringAlertCard extends StatelessWidget {
),
SizedBox
(
height:
24
.
h
),
Expanded
(
child:
alerts
.
i
sEmpty
?
_buildEmpty
()
:
_buildList
(),
child:
ha
sEmpty
?
_buildEmpty
()
:
_buildList
(),
),
],
),
...
...
@@ -47,9 +47,20 @@ class MonitoringAlertCard extends StatelessWidget {
Widget
_buildEmpty
()
{
return
Center
(
child:
Text
(
'暂无告警信息'
,
style:
TextStyle
(
color:
Colors
.
white70
,
fontSize:
18
.
sp
),
child:
Column
(
mainAxisAlignment:
MainAxisAlignment
.
center
,
children:
[
Image
.
asset
(
'lib/assets/monitoring/cat_stand.png'
,
width:
160
.
w
,
height:
163
.
h
,
),
SizedBox
(
height:
40
.
h
),
Text
(
'设备运行正常'
,
style:
TextStyle
(
color:
Colors
.
white
,
fontSize:
32
.
sp
),
),
],
),
);
}
...
...
@@ -58,7 +69,7 @@ class MonitoringAlertCard extends StatelessWidget {
return
ListView
.
separated
(
// padding: EdgeInsets.symmetric(vertical: 6.h),
itemCount:
alerts
.
length
,
separatorBuilder:
(
_
,
__
)
=>
SizedBox
(
height:
16
.
h
),
separatorBuilder:
(
_
,
__
)
=>
SizedBox
(
height:
32
.
h
),
itemBuilder:
(
context
,
index
)
{
final
item
=
alerts
[
index
];
final
pending
=
item
.
status
.
contains
(
'待处理'
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment