From 24b00a82a34eb11c6ec1bc1ce018a6e969e791d0 Mon Sep 17 00:00:00 2001
From: riku <risaku@163.com>
Date: 星期五, 15 十二月 2023 17:32:11 +0800
Subject: [PATCH] 1. 新增自动评估记录的获取和展示; 2. 新增评估记录排序功能; 3. 新增评估任务界面;

---
 src/views/fytz/user/UserInfo.vue |   29 +++++++++++++++--------------
 1 files changed, 15 insertions(+), 14 deletions(-)

diff --git a/src/views/fytz/user/UserInfo.vue b/src/views/fytz/user/UserInfo.vue
index 27d814e..2d9bcd2 100644
--- a/src/views/fytz/user/UserInfo.vue
+++ b/src/views/fytz/user/UserInfo.vue
@@ -52,7 +52,7 @@
         </template>
       </el-table-column>
       <el-table-column prop="userInfo.usertype" label="鐢ㄦ埛绫诲瀷" width="90" />
-      <el-table-column fixed="right" align="right" label="鎿嶄綔" width="140">
+      <el-table-column fixed="right" align="right" label="鎿嶄綔" width="160">
         <template #header>
           <el-button
             icon="DocumentAdd"
@@ -70,13 +70,13 @@
             @click="editRow(scope)"
             >鏌ョ湅</el-button
           >
-          <!-- <el-button
+          <el-button
             :loading="scope.row.loading2"
-            :type="scope.row.extension1 != '0' ? 'danger' : 'primary'"
+            :type="scope.row.userInfo.isenable != '0' ? 'danger' : 'primary'"
             size="small"
             @click="itemActive(scope)"
-            >{{ scope.row.extension1 != '0' ? '涓嬬嚎' : '涓婄嚎' }}</el-button
-          > -->
+            >{{ scope.row.userInfo.isenable != '0' ? '涓嬬嚎' : '涓婄嚎' }}</el-button
+          >
         </template>
       </el-table-column>
     </template>
@@ -147,24 +147,25 @@
     },
     editRow(scope) {
       scope.row.loading1 = true;
-      this.loadingStore.loadingStatus.push(() => (scope.row.loading1 = false));
-      this.$router.push(`userEdit/${scope.row.biGuid}`);
+      this.loadingStore.pushLoading(() => (scope.row.loading1 = false));
+      this.$router.push(`userEdit/${scope.row.userInfo.guid}`);
     },
     itemActive(scope) {
-      const rb = {};
-      rb.guid = scope.row.guid;
-      rb.extension1 = scope.row.extension1 != '0' ? '0' : '1';
-      const msg = scope.row.extension1 != '0' ? '涓嬬嚎' : '涓婄嚎';
+      const param = {
+        guid: scope.row.userInfo.guid,
+        isenable: !scope.row.userInfo.isenable
+      }
+      const msg = scope.row.userInfo.isenable ? '涓嬬嚎' : '涓婄嚎';
       useMessageBoxTip({
         confirmMsg: `纭${msg}璇ュ満鏅紵`,
         confirmTitle: msg,
         onConfirm: () => {
           scope.row.loading2 = true;
           return userApi
-            .updateScene(rb)
+            .updateUserInfo(param)
             .then((res) => {
-              if (res == 1) {
-                scope.row.extension1 = rb.extension1;
+              if (res.success) {
+                scope.row.userInfo.isenable = param.isenable;
               }
             })
             .finally(() => {

--
Gitblit v1.9.3