Sfoglia il codice sorgente

fix:内审进程查询

zhangjingyuan 3 anni fa
parent
commit
72e20e7d7d
1 ha cambiato i file con 97 aggiunte e 67 eliminazioni
  1. 97 67
      src/views/system/jbdScan/goods/neishenzhuangtai.vue

+ 97 - 67
src/views/system/jbdScan/goods/neishenzhuangtai.vue

@@ -1,14 +1,14 @@
 <template>
   <div class="bg">
     <el-dialog
-      width="60vw"
+      width="70vw"
       height="50vh"
       :modal-append-to-body="false"
       title="内审进度查询"
       :visible.sync="scanVisible"
     >
       <!-- 表单是否显示 -->
-      <div style="height: 75vh; width: 100%">
+      <div style="height: 75vh; width: 98%">
         <div id="box">
           <div class="overall">
             <!-- 步骤条盒子 -->
@@ -19,10 +19,7 @@
                 <div class="line">
                   <span
                     class="plan"
-                    :style="`width:${
-                      activeIndex * (100 / (stepList.length - 1)) -
-                      100 / (stepList.length - 1) / 2
-                    }%`"
+                    :style="`width:${activeIndex * (100 / (stepList.length - 1)) -100 / (stepList.length - 1) / 2}%`"
                   ></span>
                 </div>
                 <!-- 每步部分底部文字描述 -->
@@ -30,25 +27,21 @@
                   class="step"
                   v-for="(i, index) in stepList"
                   :key="index"
-                  :class="
-                    activeIndex == i.stepIndex || i.stepIndex <= activeIndex
-                      ? 'step-active'
-                      : ''
-                  "
+                  :class="activeIndex == i.stepIndex || i.stepIndex <= activeIndex? 'step-active': ''"
                 >
                   <span class="step-num">
                     <i class="el-icon-caret-right icon" v-if="index != 0"></i>
                     <p cla>{{ i.title }}</p>
-                    <!-- <span class="num">{{ i.stepIndex }}</span> -->
                   </span>
-                  <p class="title"></p>
+                  <p class="post">{{i.post}}</p>
                 </span>
+                <!-- <span></span> -->
               </div>
               <!-- 步骤条对应内容 -->
               <div class="Article-content"></div>
             </div>
           </div>
-          <div style="width: 90%; margin: 0 auto">
+          <div style="width: 90%; margin: 50px auto 0px">
             <div class="main">
               <div class="wheel-title">内审核查完成率</div>
               <div id="main"></div>
@@ -58,7 +51,7 @@
           <div v-if="CNASTableData.length > 0">
             <div class="cnas">
               <div style="width: 90%; margin: 0 auto; line-height: 35px">
-                内审不符合项(CNAS)
+                内审不符合项汇总表(CNAS)
               </div>
               <el-table :data="CNASTableData" border style="width: 90%; margin: 0 auto">
                 <el-table-column
@@ -120,7 +113,7 @@
           <div v-if="CMAtable.length > 0">
             <div class="cma">
               <div style="width: 90%; margin: 0 auto; line-height: 35px">
-                内审不符合项(CMA)
+                内审不符合项汇总表(CMA)
               </div>
               <el-table
                 :data="CMAtable"
@@ -221,40 +214,49 @@ export default {
       //步骤条步数
       stepList: [
         {
-          stepIndex: 5,
+          stepIndex: 11,
+          title: "内审计划编制",
+          post:'质量负责人'
+        },
+        {
+          stepIndex: 22,
           title: "内审实施计划编制",
+          post:'内审组长'
         },
         {
-          stepIndex: 15,
+          stepIndex: 33,
           title: "检查表编制",
+          post:'内审员'
         },
         {
-          stepIndex: 30,
+          stepIndex: 44,
           title: "首次会议",
+          post:'内审组长'
         },
         {
-          stepIndex: 45,
+          stepIndex: 55,
           title: "内部审核",
+          post:'内审员'
         },
         {
-          stepIndex: 60,
+          stepIndex: 66,
           title: "末次会议",
+          post:'内审组长'
         },
         {
-          stepIndex: 75,
+          stepIndex: 77,
           title: "不符合项整改",
+          post:'内审员/部门负责人'
         },
         {
-          stepIndex: 95,
+          stepIndex: 88,
           title: "内审报告",
+          post:'内审组长'
         },
-        // {
-        //   stepIndex: 8,
-        //   title: "不符合项跟踪",
-        // },
         {
           stepIndex: 100,
           title: "内审结束",
+          post:''
         },
       ],
       CNASTableData: [], //cnas
@@ -278,14 +280,29 @@ export default {
       }
     },
     partFilter: function (value, arr) {
-      for (let i = 0; i < arr.length; i++) {
-        console.log(arr[i])
-        if (arr[i].ID_ == value) {
-          return arr[i].NAME_;
-        }else{
-          return value
-        }
-      }
+      return value
+      // if(value.includes(",")){
+      //   let part = "";
+      //   let parts = []
+      //   parts = value.split(',');
+      //   for(let item of arr){
+      //     for(let j = 0; j < parts.length; j++) {
+      //       if(item.ID_ == parts[j]){
+      //         part = part +","+ item.NAME_;
+      //       }
+      //     }
+      //   }
+      //   return part.slice(1,part.length)
+      // }else{  
+      // for (let i = 0; i < arr.length; i++) {
+      //   console.log(arr[i])
+      //   if (arr[i].ID_ == value) {
+      //     return arr[i].NAME_;
+      //   }else{
+      //     return value
+      //   }
+      // }
+      // }
     },
   },
   watch: {
@@ -588,22 +605,24 @@ export default {
     },
     jieduan(value) {
       if (value.includes("1")) {
-        return 5;
+        return 11;
       } else if (value.includes("2")) {
-        return 15;
+        return 22;
       } else if (value.includes("3")) {
-        return 30;
+        return 33;
       } else if (value.includes("4")) {
-        return 45;
+        return 44;
       } else if (value.includes("5")) {
-        return 60;
+        return 55;
       } else if (value.includes("6")) {
-        return 75;
+        return 66;
       } else if (value.includes("7")) {
-        return 90;
+        return 77;
       } else if (value.includes("8")) {
+        return 88;
+      }else if (value.includes("8")) {
         return 100;
-      } else {
+      }else {
         return 0;
       }
     },
@@ -651,16 +670,27 @@ export default {
       let arrr = arr;
       let newarr = [];
       let obj = {};
+      let str =""
       let sql = "select ID_,NAME_ FROM  ibps_party_org";
       await repostCurd("sql", sql).then((res) => {
         let arr1 = res.variables.data;
         arr.forEach((item, index) => {
+          str =""
           arr1.forEach((it) => {
-            if (item.ze_ren_shi_ == it.ID_) {
+            debugger
+            if (item.ze_ren_shi_ == it.ID_ && !item.ze_ren_shi_.includes(",")) {
               arr[index].ze_ren_shi_ = it.NAME_;
             }
+            if(item.ze_ren_shi_.includes(",")&& item.ze_ren_shi_.includes(it.ID_)){
+              str += "," + it.NAME_
+            }
           });
+          if(str){
+            arr[index].ze_ren_shi_ = str.slice(1,str.length);
+          }
         });
+
+
       });
       let map = new Map();
       for (let item of arr) {
@@ -683,16 +713,15 @@ export default {
         this.loading = false;
       });
       type == "CMA" ? (this.cmaPieData = newarr) : (this.cnasPieData = newarr);
-      console.log(this.cnasPieData);
       callBlack();
     },
     getInit() {
       let data = this.obj[0];
       let jieduanvalue;
       if (data.shi_fou_guo_shen_ == "已编制" && data.jie_dian_ren_wu_ == "") {
-        jieduanvalue = "1";
-      } else if (data.shi_fou_guo_shen_ == "1" && data.jie_dian_ren_wu_ == "") {
         jieduanvalue = "2";
+      } else if (data.shi_fou_guo_shen_ == "1" && data.jie_dian_ren_wu_ == "") {
+        jieduanvalue = "3";
       } else {
         jieduanvalue = data.jie_dian_ren_wu_;
       }
@@ -704,13 +733,9 @@ export default {
       let this_ = this;
       this_.CNASTableData = [];
       this_.CMAtable = [];
-      let sql =
-        "select * FROM t_nsbfhxjlhzb WHERE wai_jian_ =(SELECT id_  FROM t_nshyjyb WHERE ji_hua_zong_wai_j ='" +
-        id +
-        "' ORDER BY create_time_ DESC LIMIT 1)";
+      let sql ="select * FROM t_nsbfhxjlhzb WHERE wai_jian_ =(SELECT id_  FROM t_nshyjyb WHERE ji_hua_zong_wai_j ='" +id +"' ORDER BY create_time_ DESC LIMIT 1)";
       await repostCurd("sql", sql).then((res) => {
         let data = res.variables.data;
-
         data.forEach((item) => {
           if (item.ping_shen_yi_ju_.includes("RB")) {
             this_.CMAtable.push(item);
@@ -720,16 +745,8 @@ export default {
         });
         this_.$nextTick(() => {
           if (this_.CNASTableData.length > 0) {
-            this_.getNoData(
-              this_.CNASTableData,
-              "CNAS",
-              this_.getLoadEchartsTwo
-            );
-            this_.getPieData(
-              this_.CNASTableData,
-              "CNAS",
-              this_.getLoadEchartsthree
-            );
+            this_.getNoData(this_.CNASTableData,"CNAS",this_.getLoadEchartsTwo);
+            this_.getPieData(this_.CNASTableData,"CNAS",this_.getLoadEchartsthree);
           }
           if (this_.CMAtable.length > 0) {
             this_.getNoData(this_.CMAtable, "CMA", this_.getLoadCmaEchartsX);
@@ -751,9 +768,10 @@ export default {
     margin: 0 auto;
     .wheel-title {
       position: absolute;
-
       top: 60px;
       left: -8px;
+      top: 86%;
+      left: calc(90% - 205px);
       // color: #000;
       // font-weight: bold;
     }
@@ -774,12 +792,14 @@ export default {
     height: 2px;
     position: relative;
     margin: 10px auto;
+    display: flex;
+    justify-content: space-between;
     // <!-- 步骤条背景进度条 -->
     .line {
       display: block;
       margin: 0 auto;
       position: absolute;
-      top: 24px;
+      top: 27px;
       left: 5%;
       background: #8ab4f3;
       width: 95%;
@@ -795,6 +815,7 @@ export default {
       }
     }
     .Article-steps {
+      width: 100%;
       display: flex;
       justify-content: space-between;
       .step {
@@ -802,12 +823,11 @@ export default {
           font-size: 17px;
           font-weight: bold;
           color: #808080;
-          margin-top: 5px;
         }
         .step-num {
           position: absolute;
-          width: 50px;
-          height: 50px;
+          width: 58px;
+          height: 58px;
           display: inline-block;
           line-height: 50px;
           background: #808080;
@@ -842,6 +862,16 @@ export default {
             display: inline-block;
           }
         }
+        .post{
+          text-align: center;
+          font-size: 12px;
+          margin-top: 5px;
+          position: absolute;
+          top: 60px;
+          color: #2d7df5;
+          width: 60px;
+          overflow: hidden;
+        }
       }
     }