Browse Source

fix(qualityControlAnalysisReport): 修复部门类型判断和参数处理逻辑

修复质量分析报告组件中部门类型判断条件错误的问题,将isBrigadeType改为isDepartmentType
优化风险隐患组件中的参数处理逻辑,调整scopeType参数映射并删除处理后的参数
huoyi 3 days ago
parent
commit
8901b1c9dc

+ 2 - 7
src/pages/qualityControlAnalysisReport/components/qualityControl.vue

@@ -6,7 +6,7 @@
6
     </view>
6
     </view>
7
 
7
 
8
     <!-- 任务计划安排统计 -->
8
     <!-- 任务计划安排统计 -->
9
-    <view class="task-planning" v-show="!isTeamType && !isUserType && !isBrigadeType">
9
+    <view class="task-planning" v-show="!isTeamType && !isUserType && !isDepartmentType">
10
       <view class="planning-header">
10
       <view class="planning-header">
11
         <text class="header-text">任务计划安排统计</text>
11
         <text class="header-text">任务计划安排统计</text>
12
       </view>
12
       </view>
@@ -560,12 +560,7 @@ export default {
560
             name: '问题分布',
560
             name: '问题分布',
561
             type: 'pie',
561
             type: 'pie',
562
             radius: '50%',
562
             radius: '50%',
563
-            data: [
564
-              { value: 35, name: '设备设施问题' },
565
-              { value: 45, name: '人员操作问题' },
566
-              { value: 15, name: '管理问题' },
567
-              { value: 5, name: '其他问题' }
568
-            ],
563
+            data: [],
569
             emphasis: {
564
             emphasis: {
570
               itemStyle: {
565
               itemStyle: {
571
                 shadowBlur: 10,
566
                 shadowBlur: 10,

+ 7 - 4
src/pages/qualityControlAnalysisReport/components/riskHazard.vue

@@ -253,7 +253,7 @@ export default {
253
   computed: {
253
   computed: {
254
     // 查获排名表格列配置
254
     // 查获排名表格列配置
255
     captureRankColumns() {
255
     captureRankColumns() {
256
-      
256
+
257
       const deptLabel = this.isStationType ? '大队' : this.isBrigadeType ? '主管' : this.isDepartmentType ? '班组' : this.isTeamsType ? '姓名' : '';
257
       const deptLabel = this.isStationType ? '大队' : this.isBrigadeType ? '主管' : this.isDepartmentType ? '班组' : this.isTeamsType ? '姓名' : '';
258
 
258
 
259
       return [
259
       return [
@@ -792,19 +792,22 @@ export default {
792
       }
792
       }
793
 
793
 
794
       const { scopedType = "", scopedId } = processedParams ? processedParams : { scopedType: "", scopedId: "" }
794
       const { scopedType = "", scopedId } = processedParams ? processedParams : { scopedType: "", scopedId: "" }
795
+
795
       let otherParams = {
796
       let otherParams = {
796
-        ...(scopedType == 'MANAGER'||scopedType=='BRIGADE' ? { brigadeId: scopedId } : {}),
797
-        ...(scopedType == 'DEPARTMENT' ? { departmentId: scopedId } : {}),
797
+        ...(scopedType == 'BRIGADE' ? { brigadeId: scopedId } : {}),
798
+        ...(scopedType == 'MANAGER' ? { departmentId: scopedId } : {}),
798
         ...(scopedType == 'TEAMS' ? { teamId: scopedId } : {}),
799
         ...(scopedType == 'TEAMS' ? { teamId: scopedId } : {}),
799
         ...(scopedType == 'USER' ? { userId: scopedId } : {})
800
         ...(scopedType == 'USER' ? { userId: scopedId } : {})
800
       }
801
       }
801
-      
802
+
802
       if (scopedType != 'TEAMS') {
803
       if (scopedType != 'TEAMS') {
803
         delete otherParams.teamId;
804
         delete otherParams.teamId;
804
       }
805
       }
805
       if (scopedType != 'USER') {
806
       if (scopedType != 'USER') {
806
         delete otherParams.userId;
807
         delete otherParams.userId;
807
       }
808
       }
809
+      delete processedParams.scopedType;
810
+      delete processedParams.scopedId;
808
 
811
 
809
       return { ...processedParams, ...otherParams }
812
       return { ...processedParams, ...otherParams }
810
     },
813
     },