From 0519d875ecdd5f3b1bb143acd7f8de5a2d32371e Mon Sep 17 00:00:00 2001
From: liuyg <376836862@qq.com>
Date: Sat, 14 Aug 2021 09:25:19 +0800
Subject: [PATCH] 许可审批和备案审批按钮

---
 src/views/record/record.vue |   75 ++++++++++++++++++++++---------------
 1 files changed, 45 insertions(+), 30 deletions(-)

diff --git a/src/views/record/record.vue b/src/views/record/record.vue
index 4011d10..4290aa7 100644
--- a/src/views/record/record.vue
+++ b/src/views/record/record.vue
@@ -44,8 +44,8 @@
           icon="el-icon-edit"
           :size="size"
           :type="type"
-          v-show="row.type != 0 && row.type != 1"
           @click.stop="rowDel(row)"
+          v-show="row.type == 2"
           >审批
         </el-button>
         <el-button
@@ -99,6 +99,18 @@
         <el-button type="primary" @click="Print">打 印</el-button>
       </span>
     </el-dialog>
+    <el-dialog
+      title=""
+      :visible.sync="dialogVisiblecc"
+      width="30%"
+      :modal-append-to-body="false"
+    >
+      <span>是否通过审核?</span>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="closecc">通过</el-button>
+        <el-button type="primary" @click="subcc">不通过</el-button>
+      </span>
+    </el-dialog>
   </basic-container>
 </template>
  
@@ -109,6 +121,9 @@
 export default {
   data() {
     return {
+      dialogVisiblecc: false, //许可证审核抽屉
+      xukezData: {},
+
       dialogVisible: false, // 备案审批打印的
       form: {},
       query: {},
@@ -172,7 +187,7 @@
             ],
           },
           {
-            label: "成立日期",
+            label: "注册时间",
             prop: "establishtime",
             type: "date",
             format: "yyyy-MM-dd",
@@ -180,7 +195,7 @@
             rules: [
               {
                 required: true,
-                message: "请输入成立日期",
+                message: "请输入注册时间",
                 trigger: "blur",
               },
             ],
@@ -327,6 +342,21 @@
             ],
           },
           {
+            label: "审批时间",
+            hide: true,
+            prop: "examinetime",
+            type: "date",
+            format: "yyyy-MM-dd HH:mm:ss",
+            valueFormat: "yyyy-MM-dd HH:mm:ss",
+            rules: [
+              {
+                required: true,
+                message: "请输入审批时间",
+                trigger: "blur",
+              },
+            ],
+          },
+          {
             label: "发证时间",
             hide: true,
             prop: "officetime",
@@ -455,33 +485,18 @@
       );
     },
     rowDel(row) {
-      this.$confirm("是否通过?", {
-        confirmButtonText: "通过",
-        cancelButtonText: "不通过",
-        type: "warning",
-      })
-        .then(() => {
-          row.type = "0";
-          row.examinetime = this.getCurrentTime();
-          return update(row);
-        })
-        .then(() => {
-          this.onLoad(this.page);
-          this.$message({
-            type: "success",
-            message: "操作成功!",
-          });
-        })
-        .catch(() => {
-          row.type = "1";
-          return update(row);
-          // update(row);
-          // this.onLoad(this.page);
-          // this.$message({
-          //   type: "warning",
-          //   message: "操作成功!",
-          // });
-        });
+      this.dialogVisiblecc = true;
+      this.xukezData = row;
+    },
+    closecc() {
+      this.xukezData.type = "0";
+      this.dialogVisiblecc = false;
+      return update(this.xukezData);
+    },
+    subcc() {
+      this.xukezData.type = "1";
+      this.dialogVisiblecc = false;
+      return update(this.xukezData);
     },
     // 审批打印
     rowPrint(row) {

--
Gitblit v1.9.3