From f979c8991929e0e8372f86b34537172d77c3739e Mon Sep 17 00:00:00 2001
From: zhanghua <314079846@qq.com>
Date: 星期三, 14 十二月 2022 14:36:11 +0800
Subject: [PATCH] Merge branch 'master' of http://42.193.1.25:9521/r/sccg_ui

---
 src/views/intelligentPatrol/studyJudge/inspectionTable/index.vue |  208 +++++++++++++++++++++++++--------------------------
 1 files changed, 103 insertions(+), 105 deletions(-)

diff --git a/src/views/intelligentPatrol/studyJudge/inspectionTable/index.vue b/src/views/intelligentPatrol/studyJudge/inspectionTable/index.vue
index e4f3a21..11dfc85 100644
--- a/src/views/intelligentPatrol/studyJudge/inspectionTable/index.vue
+++ b/src/views/intelligentPatrol/studyJudge/inspectionTable/index.vue
@@ -2,8 +2,8 @@
   <div class="mainContent">
     <!-- 鏁版嵁灞曠ず -->
     <el-table ref="multipleTable"
-              :header-cell-style="{background:'#06122c','font-size':'12px',color:'#4b9bb7','font-weight':'650','line-height':'45px'}"
-              :data="tableData" style="width: 100%" :row-class-name="tableRowClassName" @selection-change="tableChange">
+      :header-cell-style="{ background: '#06122c', 'font-size': '12px', color: '#4b9bb7', 'font-weight': '650', 'line-height': '45px' }"
+      :data="tableData" style="width: 100%" :row-class-name="tableRowClassName" @selection-change="tableChange">
       <el-table-column type="selection" min-width="5">
       </el-table-column>
       <el-table-column prop="code" label="浜嬩欢缂栧彿" min-width="18">
@@ -16,32 +16,31 @@
           <span>{{ scope.row.eventSource === 2 ? '瑙嗛涓婁紶' : '浜哄伐涓婁紶' }}</span>
         </template>
       </el-table-column>
-      <el-table-column :prop="mystatus === 1 ? 'category' :'category'"
-                       :label="mystatus===1 ? '澶х被鍚嶇О' : '杩濆缓绫诲埆'" :min-width="mystatus===1?'10':'15'">
+      <el-table-column :prop="mystatus === 1 ? 'category' : 'category'" :label="mystatus === 1 ? '澶х被鍚嶇О' : '杩濆缓绫诲埆'"
+        :min-width="mystatus === 1 ? '10' : '15'">
       </el-table-column>
-      <el-table-column :prop="mystatus === 1 ? 'type' :'site'" :label="mystatus===1 ? '灏忕被鍚嶇О' : '杩濆缓鍦扮偣'"
-                       min-width="10">
+      <el-table-column :prop="mystatus === 1 ? 'type' : 'site'" :label="mystatus === 1 ? '灏忕被鍚嶇О' : '杩濆缓鍦扮偣'" min-width="10">
       </el-table-column>
-      <el-table-column :prop="mystatus === 1 ? 'site' :''" :label="mystatus===1 ? '鎶ヨ鐐逛綅' : '杩濇硶寤虹瓚闀裤�佸銆侀珮'"
-                       :min-width="mystatus===1?'10' :'20' ">
+      <el-table-column :prop="mystatus === 1 ? 'site' : ''" :label="mystatus === 1 ? '鎶ヨ鐐逛綅' : '杩濇硶寤虹瓚闀裤�佸銆侀珮'"
+        :min-width="mystatus === 1 ? '10' : '20'">
         <template slot-scope="scope">
-          <div v-if="mystatus ===2"><span>{{
+          <div v-if="mystatus === 2"><span>{{
               scope.row.buildingLength + '绫�' + '銆�' +
               scope.row.buildingWidth + '绫�' + '銆�' + scope.row.buildingHigh + '绫�'
-            }}</span></div>
+          }}</span></div>
           <div v-else>{{ scope.row.site }}</div>
         </template>
       </el-table-column>
-      <el-table-column :prop="mystatus === 1 ? 'street' :'buildingArea'"
-                       :label="mystatus===1 ? '鎵�灞炲尯鍩�' : '杩濇硶寤虹瓚闈㈢Н'" min-width="12">
+      <el-table-column :prop="mystatus === 1 ? 'street' : 'buildingArea'" :label="mystatus === 1 ? '鎵�灞炲尯鍩�' : '杩濇硶寤虹瓚闈㈢Н'"
+        min-width="12">
       </el-table-column>
-      <el-table-column prop="alarmTime" label="鎶ヨ鏃堕棿" min-width="15" v-if="mystatus===1">
+      <el-table-column prop="alarmTime" label="鎶ヨ鏃堕棿" min-width="15" v-if="mystatus === 1">
         <template slot-scope="scope">
           <span>{{ filterTime(scope.row.alarmTime) }}</span>
         </template>
       </el-table-column>
-      <el-table-column :prop="mystatus === 1 ? 'continueTime' :'materials'"
-                       :label="mystatus===1 ? '鎸佺画鏃堕棿' : '杩濇硶寤虹瓚鏉愭枡'" min-width="12">
+      <el-table-column :prop="mystatus === 1 ? 'continueTime' : 'materials'" :label="mystatus === 1 ? '鎸佺画鏃堕棿' : '杩濇硶寤虹瓚鏉愭枡'"
+        min-width="12">
       </el-table-column>
       <el-table-column prop="operation" label="鎿嶄綔" min-width="20">
         <template slot-scope="scope">
@@ -57,45 +56,24 @@
     <div class="tools">
       <div class="funs">
         <div class="funsItem funs-sp">
-          <el-checkbox v-model="all" @change="selectAll()"
-          >鍏ㄩ��
-          </el-checkbox
-          >
+          <el-checkbox v-model="all" @change="selectAll()">鍏ㄩ��
+          </el-checkbox>
         </div>
         <div class="funsItem funs-sp">
-          <el-checkbox v-model="unsame" @change="disSame(tableData)"
-          >鍙嶉��
-          </el-checkbox
-          >
+          <el-checkbox v-model="unsame" @change="disSame(tableData)">鍙嶉��
+          </el-checkbox>
         </div>
         <div class="funsItem">
-          <el-select
-              v-model="myIdx"
-              placeholder="鎵归噺鎿嶄綔"
-              @change="selectChange"
-          >
-            <el-option
-                v-for="item in options"
-                :key="item.value"
-                :label="item.label"
-                :value="item.value"
-                :disabled="item.disabled"
-            >
+          <el-select v-model="myIdx" placeholder="鎵归噺鎿嶄綔" @change="selectChange">
+            <el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value"
+              :disabled="item.disabled">
             </el-option>
           </el-select>
         </div>
       </div>
       <div class="pagination">
-        <el-pagination
-            background
-            :current-page="currentPage"
-            layout="prev, pager, next"
-            :total="totalNum"
-            :page-size="pageSize"
-            @current-change="changeCurrentPage"
-            @prev-click="handlePrev"
-            @next-click="handleNext"
-        >
+        <el-pagination background :current-page="currentPage" layout="prev, pager, next" :total="totalNum"
+          :page-size="pageSize" @current-change="changeCurrentPage" @prev-click="handlePrev" @next-click="handleNext">
         </el-pagination>
       </div>
     </div>
@@ -136,7 +114,7 @@
       currentPage: 1,
       all: false,
       unsame: false,
-      tempList:[]
+      tempList: []
     }
   },
   methods: {
@@ -170,25 +148,46 @@
       }
     },
     mulHandler(ids, option) {
-      console.log("whj", ids, option)
-      console.log(this.options.filter(x => x.value === option))
+      // debugger
+      // console.log("whj", ids, option)
+      // console.log(this.options.filter(x => x.value === option))
       const tag = this.options.filter(x => x.value === option)[0].label
       if (option === 3) {
         this.$confirm(`鎮ㄧ‘瀹氳${tag}鍚�?`)
-            .then((_) => {
-
+          .then((_) => {
+            this.$axios({
+              method: 'put',
+              url: `/sccg/base_case/batch_case_study?ids=${ids}`,
             })
-            .catch((err) => {
-              console.log(err);
-            });
+              .then(res => {
+                this.$message({
+                  type: res.code === 200 ? 'success' : 'warning',
+                  message: res.message+",浜嬩欢宸茬粡鎵归噺澶勭悊,璇疯繘鍏ユ浠舵睜鍦ㄥ涔�"
+                })
+                this.getInspectionData();
+              })
+          })
+          .catch((err) => {
+            console.log(err);
+          });
       } else if (option === 4) {
         this.$confirm(`鎮ㄧ‘瀹氳${tag}鍚�?`)
-            .then((_) => {
-
+          .then((_) => {
+            this.$axios({
+              method: 'put',
+              url: `/sccg/base_case/batch_case_Ignore?ids=${ids}`,
             })
-            .catch((err) => {
-              console.log(err);
-            });
+              .then(res => {
+                this.$message({
+                  type: res.code === 200 ? 'success' : 'warning',
+                  message: res.message+",浜嬩欢宸茬粡鎵归噺澶勭悊,璇疯繘鍏ユ浠舵睜鍦ㄥ涔�"
+                })
+                this.getInspectionData();
+              })
+          })
+          .catch((err) => {
+            console.log(err);
+          });
       }
     },
     handlePrev(page) {
@@ -211,7 +210,7 @@
         this.$refs.multipleTable.toggleRowSelection(row);
       });
     },
-    tableRowClassName({row, rowIndex}) {
+    tableRowClassName({ row, rowIndex }) {
       if ((rowIndex + 1) % 2 === 0) {
         return 'warning-row';
       } else {
@@ -227,12 +226,12 @@
         type: 1
       }
       basecase
-          .baseCasePoolList(params)
-          .then(({records, total}) => {
-            this.tableData = records;
-            this.totalNum = total;
-          })
-          .catch(err => this.$message.error(err))
+        .baseCasePoolList(params)
+        .then(({ records, total }) => {
+          this.tableData = records;
+          this.totalNum = total;
+        })
+        .catch(err => this.$message.error(err))
     },
     async JumpView(data) {
       await this.getEventInfo(data.code);
@@ -243,65 +242,64 @@
         method: 'get',
         url: `sccg/base_case/baseCaseDetail/${code}`
       })
-          .then(res => {
-            this.info = res.data;
-            this.dialogView = true;
-          })
+        .then(res => {
+          this.info = res.data;
+          this.dialogView = true;
+        })
     },
     filterTime(time) {
       return helper(time);
     },
-    handleLearn({id}) {
+    handleLearn({ id }) {
       this.$axios({
         method: 'put',
         url: 'sccg/base_case/case_status_update?caseId=' + id + '&state=' + 3
       })
-          .then(res => {
-            if (res.code === 200) {
-              this.$notify({
-                title: '娓╅Θ鎻愮ず',
-                message: '姝や簨浠跺凡蹇界暐,杩斿洖绯荤粺鍦ㄥ涔�',
-                type: 'success',
-                position: 'bottom-right'
-              })
-              this.getInspectionData();
-            } else {
-              this.$message({
-                type: 'error',
-                message: '鎿嶄綔澶辫触'
-              })
-            }
-          })
+        .then(res => {
+          if (res.code === 200) {
+            this.$notify({
+              title: '娓╅Θ鎻愮ず',
+              message: '姝や簨浠跺凡蹇界暐,杩斿洖绯荤粺鍦ㄥ涔�',
+              type: 'success',
+              position: 'bottom-right'
+            })
+            this.getInspectionData();
+          } else {
+            this.$message({
+              type: 'error',
+              message: '鎿嶄綔澶辫触'
+            })
+          }
+        })
     },
     // 鏆備笉澶勭悊
-    handleNotDeal({id}) {
+    handleNotDeal({ id }) {
       this.$axios({
         method: 'put',
         url: 'sccg/base_case/case_status_update?caseId=' + id + '&state=' + 4
       })
-          .then(res => {
-            if (res.code === 200) {
-              this.$notify({
-                title: '娓╅Θ鎻愮ず',
-                message: '姝や簨浠舵殏涓嶅鐞�,璇峰墠寰�鏆備笉澶勭悊鐣岄潰鏌ョ湅璇︽儏',
-                type: 'success',
-                position: 'bottom-right'
-              })
-              this.getInspectionData();
-            } else {
-              this.$message({
-                type: 'error',
-                message: '鎿嶄綔澶辫触'
-              })
-            }
-          })
+        .then(res => {
+          if (res.code === 200) {
+            this.$notify({
+              title: '娓╅Θ鎻愮ず',
+              message: '姝や簨浠舵殏涓嶅鐞�,璇峰墠寰�鏆備笉澶勭悊鐣岄潰鏌ョ湅璇︽儏',
+              type: 'success',
+              position: 'bottom-right'
+            })
+            this.getInspectionData();
+          } else {
+            this.$message({
+              type: 'error',
+              message: '鎿嶄綔澶辫触'
+            })
+          }
+        })
     },
   }
 }
 </script>
 
 <style scoped lang="scss">
-
 .tools {
   display: flex;
   justify-content: space-between;
@@ -354,6 +352,7 @@
     justify-content: center;
 
     .el-pagination {
+
       &::v-deep li,
       &::v-deep .btn-prev,
       &::v-deep .btn-next {
@@ -385,5 +384,4 @@
     }
   }
 }
-
 </style>

--
Gitblit v1.8.0