Browse Source

fix(ui): 调整元素位置和样式间距问题

refactor(ProblemRectification): 优化状态图例颜色配置
fix(ProblemRectification): 修正整改状态数据映射关系
fix(InspectionExecution): 修正表格列名与数据属性对应关系
feat(inspectionStatistics): 添加切换标签时滚动到顶部功能
style: 统一调整days-count元素位置样式
chore(config): 清理注释掉的配置项
refactor(workProfile): 优化特殊用户界面显示逻辑
huoyi 3 months ago
parent
commit
ea44af6e1c

+ 2 - 2
src/config.js

@@ -4,8 +4,8 @@ module.exports = {
4 4
  // baseUrl: process.env.NODE_ENV === 'development' ? 'http://192.168.3.221:82/prod-api' : '/prod-api', //生产
5 5
   //  baseUrl: process.env.NODE_ENV === 'development' ? 'http://192.168.3.221:8080' : '/prod-api',
6 6
 // baseUrl: process.env.NODE_ENV === 'development' ? 'http://guangxi.qinghe.sundot.cn:8088' : 'http://guangxi.qinghe.sundot.cn:8088/prod-api',
7
-// baseUrl: 'http://guangxi.qinghe.sundot.cn:8088',
8
-     baseUrl:'http://airport.samsundot.com:9021/prod-api',
7
+ // baseUrl: 'http://airport.samsundot.com:9024',
8
+    baseUrl:'http://airport.samsundot.com:9021/prod-api',
9 9
   // 应用信息
10 10
   appInfo: {
11 11
     // 应用名称

+ 2 - 2
src/pages/inspectionStatistics/components/InspectionExecution.vue

@@ -88,8 +88,8 @@ export default {
88 88
       tableColumns: [
89 89
         { title: '姓名', props: 'userName' },
90 90
         { title: '今日完成比例', props: 'completionPercentage', slot: true },
91
-        { title: '整改单数', props: 'checkOrderCount' },
92
-        { title: '不合格项数', props: 'rectificationOrderCount' },
91
+        { title: '整改单数', props: 'rectificationOrderCount' },
92
+        { title: '不合格项数', props: 'unqualifiedProjectCount' },
93 93
       ],
94 94
       // 站级任务明细数据
95 95
       dataStation: [],

+ 2 - 2
src/pages/inspectionStatistics/components/InspectionPlan.vue

@@ -466,8 +466,8 @@ export default {
466 466
 
467 467
       .days-count {
468 468
         position: absolute;
469
-        right: -72rpx;
470
-         top:-8rpx;
469
+        right: -85rpx;
470
+         top:-8.5rpx;
471 471
         font-size: 25rpx;
472 472
         color: black;
473 473
         font-weight: 500;

+ 6 - 4
src/pages/inspectionStatistics/components/ProblemDiscovery.vue

@@ -392,10 +392,11 @@ export default {
392 392
     async getZhanZhangChartAndList() {
393 393
       for (let i = 0; i < this.pieChartData.length; i++) {
394 394
         //分类
395
-
395
+       
396 396
         //获取问题对比数据
397 397
         let problemCompareData = this.handleProblemDto(this.pieChartData[i].checkLargeScreenProblemDtoList)
398 398
         console.log(problemCompareData, "problemCompareData")
399
+        
399 400
         this.$set(this.pieChartData[i], 'problemCompareData', problemCompareData || [])
400 401
 
401 402
         //获取问题趋势数据
@@ -420,7 +421,7 @@ export default {
420 421
         console.warn('handleProblemDetailDto: 传入的数据不是数组或为空')
421 422
         return []
422 423
       }
423
-
424
+       
424 425
       // 按问题类型分组统计
425 426
       const problemTypeMap = {}
426 427
       arr.forEach(item => {
@@ -448,6 +449,7 @@ export default {
448 449
         //获取问题明细数据(环形图数据)
449 450
         let problemDetailData = this.handleProblemDetailDto(this.pieChartData[i].checkLargeScreenProblemDtoList)
450 451
         console.log(problemDetailData, "problemDetailData")
452
+        
451 453
         this.$set(this.pieChartData[i], 'problemDetailData', problemDetailData || [])
452 454
 
453 455
         //获取问题趋势数据
@@ -928,8 +930,8 @@ export default {
928 930
 
929 931
         .days-count {
930 932
           position: absolute;
931
-          right: -72rpx;
932
-          top:-8rpx;
933
+        right: -85rpx;
934
+          top:-8.5rpx;
933 935
           font-size: 25rpx;
934 936
           color: black;
935 937
           font-weight: 500;

+ 10 - 7
src/pages/inspectionStatistics/components/ProblemRectification.vue

@@ -169,12 +169,12 @@ export default {
169 169
         let xAxisData = [];
170 170
         let seriesData = [];
171 171
 
172
-        // 定义四种状态的数据字段映射
172
+        // 定义四种状态的数据字段映射和颜色配置
173 173
         const statusConfig = [
174
-          { key: 'onTimeCompletedCount', name: '按期完成' },
175
-          { key: 'overTimeCompletedCount', name: '超期完成' },
176
-          { key: 'onTimeUnfinishedCount', name: '按期整改中' },
177
-          { key: 'overTimeUnfinishedCount', name: '超期整改中' }
174
+          { key: 'onTimeCompletedCount', name: '按期完成', color: '#5896FC' },
175
+          { key: 'overTimeCompletedCount', name: '超期完成', color: '#FA7E7E' },
176
+          { key: 'onTimeUnfinishedCount', name: '按期整改中', color: '#00AE41' },
177
+          { key: 'overTimeUnfinishedCount', name: '超期整改中', color: '#FAC000' }
178 178
         ];
179 179
 
180 180
         // 提取部门名称作为x轴数据
@@ -186,6 +186,9 @@ export default {
186 186
             name: status.name,
187 187
             type: 'bar',
188 188
             stack: 'total',
189
+            itemStyle: {
190
+              color: status.color
191
+            },
189 192
             emphasis: {
190 193
               focus: 'series'
191 194
             },
@@ -342,8 +345,8 @@ export default {
342 345
 
343 346
         .days-count {
344 347
           position: absolute;
345
-          right: -72rpx;
346
-          top: -8rpx;
348
+          right: -85rpx;
349
+          top: -8.5rpx;
347 350
           font-size: 25rpx;
348 351
           color: black;
349 352
           font-weight: 500;

+ 7 - 2
src/pages/inspectionStatistics/index.vue

@@ -1,5 +1,5 @@
1 1
 <template>
2
-	<home-container :customStyle="{ background: 'none', paddingTop: '0' }">
2
+	<home-container :customStyle="{ background: 'none', paddingTop: '0' }" ref="homeContainer">
3 3
 		<view class="inspection-statistics">
4 4
 
5 5
 			<!-- 选项卡 -->
@@ -72,6 +72,11 @@ export default {
72 72
 		handleTabChange(index) {
73 73
 			this.activeTab = index
74 74
 			console.log('切换到选项卡:', this.tabs[index].label)
75
+			this.$nextTick(() => {
76
+				if (this.$refs.homeContainer && this.$refs.homeContainer.scrollToTop) {
77
+					this.$refs.homeContainer.scrollToTop();
78
+				}
79
+			});
75 80
 		}
76 81
 	}
77 82
 }
@@ -85,7 +90,7 @@ export default {
85 90
 	.h-tabs {
86 91
 		position: fixed;
87 92
 		top: 80rpx;
88
-        z-index: 999;
93
+		z-index: 999;
89 94
 		padding-top: 20rpx;
90 95
 		background-color: #fff !important;
91 96
 	}

+ 3 - 3
src/pages/workProfile/index.vue

@@ -3,14 +3,14 @@
3 3
 
4 4
         <view class="workProfileContainer">
5 5
             <!-- 下拉选择 -->
6
-            <div class="filter-section">
6
+            <div class="filter-section" v-if="isSpecialUser || isJingLi">
7 7
                 <uni-data-select :class="{ 'filter-select': true, 'kezhang-style': isKeZhang }" v-model="selectedLevel"
8 8
                     :localdata="levelOptions" placeholder="请选择级别" :clear="false" @change="handleLevelChange"
9 9
                     :disabled="isKeZhang" />
10 10
             </div>
11 11
 
12 12
             <!-- 总体概览 -->
13
-            <div class="overview-section">
13
+            <div class="overview-section" :style="{ marginTop:isSpecialUser || isJingLi? '80rpx':'0rpx' }">
14 14
                 <h2 class="section-title">总体概览</h2>
15 15
                 <div class="overview-cards">
16 16
                     <!-- 组织支撑 -->
@@ -120,7 +120,7 @@ export default {
120 120
     },
121 121
     async mounted() {
122 122
         await this.getDept()
123
-        this.loadData()
123
+        // this.loadData()
124 124
 
125 125
     },
126 126
     provide() {