From ae234efb788bca2fa77f700442427996fa7f4aca Mon Sep 17 00:00:00 2001
From: riku <risaku@163.com>
Date: 星期四, 14 十一月 2024 11:58:00 +0800
Subject: [PATCH] Merge branch 'hc-dataproduct-v1112' into lsf-dataproduct-1024

---
 src/views/fysp/check/ProCheck.vue |   82 ++++++++++++++++++++---------------------
 1 files changed, 40 insertions(+), 42 deletions(-)

diff --git a/src/views/fysp/check/ProCheck.vue b/src/views/fysp/check/ProCheck.vue
index 4be5761..8ca7913 100644
--- a/src/views/fysp/check/ProCheck.vue
+++ b/src/views/fysp/check/ProCheck.vue
@@ -8,7 +8,11 @@
       </SearchBar>
     </template>
     <template #aside>
-      <SideList :items="subtasks" :loading="sideLoading" @item-click="chooseSubtask"></SideList>
+      <SideList
+        :items="subtasks"
+        :loading="sideLoading"
+        @item-click="chooseSubtask"
+      ></SideList>
     </template>
     <template #main>
       <ToolBar
@@ -17,7 +21,11 @@
         :buttons="buttons"
         :loading="mainLoading"
       ></ToolBar>
-      <el-scrollbar v-if="curProList.length > 0" class="el-scrollbar" v-loading="mainLoading">
+      <el-scrollbar
+        v-if="curProList.length > 0"
+        class="el-scrollbar"
+        v-loading="mainLoading"
+      >
         <CompProblemCard
           v-if="compProblemCardVisible"
           :key="i"
@@ -47,29 +55,23 @@
       @submited="newProSubmit"
     />
   </el-dialog>
-  <el-dialog
-    v-model="anyPhotoDialog"
-    :before-close="beforeAnyPhotoDialogclose"
-    width="80%"
-    title="浠绘剰鍥剧墖"
-  >
-    <ArbitraryPhoto
-      v-if="anyPhotoDialog"
-      :readonly="true"
-      :subtask="curSubtask.data"
-      ref="arbitraryPhotoRef"
-      @selectByAnyPhonoEvent="handleCloseCheckAnyPhono"
-    >
-    </ArbitraryPhoto>
-  </el-dialog>
+  <ArbitraryPhoto
+    v-if="anyPhotoDialog"
+    v-model:dialog-visible="anyPhotoDialog"
+    title="鍦烘櫙鍥剧墖"
+    :readonly="true"
+    :subtask="curSubtask.data"
+    ref="arbitraryPhotoRef"
+  ></ArbitraryPhoto>
   <el-drawer
-    :direction="rtl"
+    direction="ltr"
     v-model="deviceShowDialog"
     :before-close="beforeDeviceShowDialogclose"
     title="璁炬柦璁惧"
-    size="65%"
+    size="45%"
   >
-    <CompDeviceShowTest v-if="deviceShowDialog" ref="deviceShowRef"> </CompDeviceShowTest>
+    <CompDeviceShowTest v-if="deviceShowDialog" ref="deviceShowRef">
+    </CompDeviceShowTest>
   </el-drawer>
 </template>
 
@@ -77,14 +79,9 @@
 import ArbitraryPhoto from './components/ArbitraryPhoto.vue';
 import taskApi from '@/api/fysp/taskApi';
 import ProCheckProxy from './ProCheckProxy';
-
-import { ElMessageBox, ElNotification, ElMessage } from 'element-plus';
 import CompProblemAddOrUpd from './components/CompProblemAddOrUpd.vue';
-import CompDeviceShow from './components/CompDeviceShow.vue';
-
 import CompProblemCard from './components/CompProblemCard.vue';
 import CompSubTaskStatistic from './components/CompSubTaskStatistic.vue';
-import CompProRecent from './components/CompProRecent.vue';
 import CompDeviceShowTest from './components/CompDeviceShowTest.vue';
 export default {
   components: {
@@ -92,8 +89,7 @@
     CompSubTaskStatistic,
     CompProblemAddOrUpd,
     ArbitraryPhoto,
-    CompDeviceShowTest,
-    CompProRecent
+    CompDeviceShowTest
   },
   data() {
     return {
@@ -126,7 +122,7 @@
           }
         },
         {
-          name: '浠绘剰鍥剧墖',
+          name: '鍦烘櫙鍥剧墖',
           color: 'warning',
           click: () => {
             this.anyPhotoDialog = true;
@@ -139,11 +135,11 @@
             this.openDeviceShowDialog();
           }
         },
-        {
-          name: '鎵归噺瀹℃牳',
-          color: 'primary',
-          click: () => {}
-        }
+        // {
+        //   name: '鎵归噺瀹℃牳',
+        //   color: 'primary',
+        //   click: () => {}
+        // }
       ]
     };
   },
@@ -237,8 +233,9 @@
       });
     },
     // 鍏抽棴璁惧鍥惧脊绐�
-    beforeDeviceShowDialogclose() {
-      this.deviceShowDialog = false;
+    beforeDeviceShowDialogclose(done) {
+      // this.deviceShowDialog = false;
+      done();
     },
     // 鍏抽棴浠绘剰鍥剧墖寮圭獥
     beforeAnyPhotoDialogclose() {
@@ -252,12 +249,16 @@
     },
     //鏌ヨ瀛愪换鍔$粺璁′俊鎭�
     search(formSearch) {
-      this.topTask = formSearch.obj;
+      this.topTask = formSearch.topTask;
       this.sideLoading = true;
       this.mainLoading = true;
       this.curProList = [];
       this.curSubtask = {};
-      taskApi.getSubtaskSummary(formSearch).then((res) => {
+      const param = {
+        topTaskId: formSearch.topTask.tguid,
+        sceneTypeId: formSearch.sceneTypeId
+      };
+      taskApi.getSubtaskSummary(param).then((res) => {
         const list = [];
         res.forEach((s) => {
           const t = this.getSubtaskType(s);
@@ -306,12 +307,9 @@
         });
     },
     // 闂鍗$墖缁勪欢涓诲姩鍙戣捣鍒锋柊鐖剁粍浠舵暟鎹�
-    updateSubtask(isOk) {
+    updateSubtask() {
       this.curSubtask.data.proCheckedNum++;
       this.curSubtask.type = this.getSubtaskType(this.curSubtask.data);
-      if (!isOk) {
-        return;
-      }
       this.refreshCurrSubtask();
     },
     onProSubmited(isOk) {
@@ -319,7 +317,7 @@
       if (!isOk) {
         return;
       }
-      this.updateSubtask(isOk);
+      this.updateSubtask();
     },
     newProSubmit(isOk) {
       this.proAddOrUpdDialogVisible = false;

--
Gitblit v1.9.3