Kaynağa Gözat

style(ui): 优化自检页面布局与文本展示格式

1. 调整卡片布局为纵向排列,新增对应样式类
2. 为设备位置和定检小组文本添加前缀标签
3. 修复部分样式注释与指示器高度配置
huoyi 3 hafta önce
ebeveyn
işleme
2a781ea530

+ 24 - 17
src/pages/home-new/components/selfCheck.vue

@@ -20,11 +20,11 @@
20
                             <text class="item-label">{{ item.serialNumber }}</text>
20
                             <text class="item-label">{{ item.serialNumber }}</text>
21
                             <text class="item-date">{{ item.date }}</text>
21
                             <text class="item-date">{{ item.date }}</text>
22
                         </view>
22
                         </view>
23
-                        <view class="item-row">
24
-                            <text class="item-label">{{ item.terminlName }}{{ item.terminlName ? '/' : '' }}{{
23
+                        <view class="item-row-column">
24
+                            <view class="item-label">设备位置:{{ item.terminlName }}{{ item.terminlName ? '/' : '' }}{{
25
                                 item.regionalName
25
                                 item.regionalName
26
-                            }}{{ item.regionalName ? '/' : '' }}{{ item.channelName }}</text>
27
-                            <text class="item-role">{{ item.role }}</text>
26
+                                }}{{ item.regionalName ? '/' : '' }}{{ item.channelName }}</view>
27
+                            <view class="item-role">定检小组:{{ item.role }}</view>
28
                         </view>
28
                         </view>
29
                     </view>
29
                     </view>
30
                 </view>
30
                 </view>
@@ -44,11 +44,11 @@
44
                             <text class="item-label">{{ item.serialNumber }}</text>
44
                             <text class="item-label">{{ item.serialNumber }}</text>
45
                             <text class="item-date">{{ item.date }}</text>
45
                             <text class="item-date">{{ item.date }}</text>
46
                         </view>
46
                         </view>
47
-                        <view class="item-row">
48
-                            <text class="item-label">{{ item.terminlName }}{{ item.terminlName ? '/' : '' }}{{
47
+                        <view class="item-row-column">
48
+                            <view class="item-label">设备位置:{{ item.terminlName }}{{ item.terminlName ? '/' : '' }}{{
49
                                 item.regionalName
49
                                 item.regionalName
50
-                            }}{{ item.regionalName ? '/' : '' }}{{ item.channelName }}</text>
51
-                            <text class="item-role">{{ item.role }}</text>
50
+                                }}{{ item.regionalName ? '/' : '' }}{{ item.channelName }}</view>
51
+                            <view class="item-role">定检小组:{{ item.role }}</view>
52
                         </view>
52
                         </view>
53
                     </view>
53
                     </view>
54
                 </view>
54
                 </view>
@@ -68,11 +68,11 @@
68
                             <text class="item-label">{{ item.serialNumber }}</text>
68
                             <text class="item-label">{{ item.serialNumber }}</text>
69
                             <text class="item-date">{{ item.date }}</text>
69
                             <text class="item-date">{{ item.date }}</text>
70
                         </view>
70
                         </view>
71
-                        <view class="item-row">
72
-                            <text class="item-label">{{ item.terminlName }}{{ item.terminlName ? '/' : '' }}{{
71
+                        <view class="item-row-column">
72
+                            <view class="item-label">设备位置:{{ item.terminlName }}{{ item.terminlName ? '/' : '' }}{{
73
                                 item.regionalName
73
                                 item.regionalName
74
-                            }}{{ item.regionalName ? '/' : '' }}{{ item.channelName }}</text>
75
-                            <text class="item-role">{{ item.role }}</text>
74
+                                }}{{ item.regionalName ? '/' : '' }}{{ item.channelName }}</view>
75
+                            <view class="item-role">定检小组:{{ item.role }}</view>
76
                         </view>
76
                         </view>
77
                     </view>
77
                     </view>
78
                 </view>
78
                 </view>
@@ -153,8 +153,8 @@ export default {
153
 <style scoped>
153
 <style scoped>
154
 .self-check-container {
154
 .self-check-container {
155
     width: 100%;
155
     width: 100%;
156
-    padding: 12px;
157
-    background-color: #f5f7fa;
156
+    /* padding: 12px;
157
+    background-color: #f5f7fa; */
158
 }
158
 }
159
 
159
 
160
 .self-check-header {
160
 .self-check-header {
@@ -227,17 +227,17 @@ export default {
227
 
227
 
228
 .item-indicator.expired {
228
 .item-indicator.expired {
229
     background-color: #FF0000;
229
     background-color: #FF0000;
230
-    height: 48px;
230
+    height: 66px;
231
 }
231
 }
232
 
232
 
233
 .item-indicator.urgent {
233
 .item-indicator.urgent {
234
     background-color: #FFA500;
234
     background-color: #FFA500;
235
-    height: 48px;
235
+    height: 66px;
236
 }
236
 }
237
 
237
 
238
 .item-indicator.normal {
238
 .item-indicator.normal {
239
     background-color: #FFD700;
239
     background-color: #FFD700;
240
-    height: 48px;
240
+    height: 66px;
241
 }
241
 }
242
 
242
 
243
 .item-content {
243
 .item-content {
@@ -253,6 +253,13 @@ export default {
253
     align-items: center;
253
     align-items: center;
254
 }
254
 }
255
 
255
 
256
+.item-row-column {
257
+    display: flex;
258
+    justify-content: space-between;
259
+    align-items: flex-start;
260
+    flex-direction: column;
261
+}
262
+
256
 .item-label {
263
 .item-label {
257
     font-size: 14px;
264
     font-size: 14px;
258
     color: #333;
265
     color: #333;

+ 9 - 3
src/pages/selfCheck/index.vue

@@ -18,9 +18,9 @@
18
                             <text class="card-label">{{ item.serialNumber }}</text>
18
                             <text class="card-label">{{ item.serialNumber }}</text>
19
                             <text class="card-date">{{ item.date }}</text>
19
                             <text class="card-date">{{ item.date }}</text>
20
                         </view>
20
                         </view>
21
-                        <view class="card-row" style="justify-content: flex-start;">
22
-                            <text class="item-label">{{ item.terminlName }}{{ item.terminlName ? '/' : '' }}{{item.regionalName}}{{ item.regionalName ? '/' : '' }}{{ item.channelName }}</text>
23
-                            <text class="card-role" style="margin-left: 10px;">{{ item.role }}</text>
21
+                        <view class="card-row-column" style="justify-content: flex-start;">
22
+                            <view class="card-label">设备位置:{{ item.terminlName }}{{ item.terminlName ? '/' : '' }}{{item.regionalName}}{{ item.regionalName ? '/' : '' }}{{ item.channelName }}</view>
23
+                            <view class="card-role">定检小组:{{ item.role }}</view>
24
                         </view>
24
                         </view>
25
                     </view>
25
                     </view>
26
                     <view :class="['status-tag', getStatusClass(item.colorType)]">
26
                     <view :class="['status-tag', getStatusClass(item.colorType)]">
@@ -241,6 +241,12 @@ export default {
241
     justify-content: space-between;
241
     justify-content: space-between;
242
     align-items: center;
242
     align-items: center;
243
 }
243
 }
244
+.card-row-column {
245
+    display: flex;
246
+    justify-content: space-between;
247
+    align-items: flex-start;
248
+    flex-direction: column;
249
+}
244
 
250
 
245
 .card-label {
251
 .card-label {
246
     font-size: 14px;
252
     font-size: 14px;