From 8fb281df7bb93d918c2bf75f29405fa9ce53bad8 Mon Sep 17 00:00:00 2001
From: liuyg <376836862@qq.com>
Date: Fri, 26 Nov 2021 16:36:23 +0800
Subject: [PATCH] +pdf预览插件

---
 src/views/securityGuard/securityGuard.vue |   34 +++++++++++++++++++++++-----------
 1 files changed, 23 insertions(+), 11 deletions(-)

diff --git a/src/views/securityGuard/securityGuard.vue b/src/views/securityGuard/securityGuard.vue
index 3342769..b7f89bc 100644
--- a/src/views/securityGuard/securityGuard.vue
+++ b/src/views/securityGuard/securityGuard.vue
@@ -826,7 +826,7 @@
                   text: " ",
                   ratio: 0.1,
                 },
-                action: "/api/blade-resource/oss/endpoint/put-file-user-avatar",
+                action: "/api/blade-resource/oss/endpoint/put-files",
                 tip: "上传身份证一寸近期彩色正面免冠图象, (358像素(宽) × 441像素(高)、分辨率350dpi)且不超过500kb",
                 span: 12,
                 // row: true,
@@ -1836,10 +1836,11 @@
         row.fingerprint = zhiwen.imgBMP;
         row.myPicture = zhiwen.featuredata;
       }
-      // console.log(row);
-      // return;
+
       //是否是身份证自动识别进入
-      row["cell"] = this.nowCell;
+      if (row.cell != "2") {
+        row["cell"] = this.nowCell;
+      }
       update(row).then(
         () => {
           this.initFlag = false;
@@ -2037,8 +2038,8 @@
       );
     },
     openClosegroup(val) {
-      let ql = /realName|nation|cardid|registered|sex/;
-      // let ql = /realName|nation|cardid|registered/;
+      // let ql = /realName|nation|cardid|registered|sex/;
+      let ql = /realName|nation|cardid|registered/;
       for (let k in this.option.group) {
         for (let i in this.option.group[k].column) {
           if (ql.test(this.option.group[k].column[i].prop)) {
@@ -2101,10 +2102,10 @@
       this.intTime = setInterval(function () {
         if (!that.haveCardid) {
           //定时读卡
-          console.log(that.haveCardid);
+          // console.log(that.haveCardid);
           let result = CertCtl.readCert();
           // console.log(result);
-          console.log("通过读取");
+          // console.log("通过读取");
           if (result == "") {
             console.log("未启动读卡插件!");
             that.closeSFZ();
@@ -2124,8 +2125,7 @@
               that.form.cardid = data.certNumber;
               that.form.nation = data.nation;
               that.form.registered = data.certAddress;
-              that.form.sex =
-                data.certType == 0 ? 2 : data.certType == 1 ? 1 : 3;
+              that.form.sex = data.gender == 0 ? 2 : data.gender == 1 ? 1 : 3;
               //禁止编辑
               that.openClosegroup(true);
               that.nowCell = "2";
@@ -2134,7 +2134,7 @@
                 console.log("读卡器未连接");
                 that.closeSFZ();
               } else {
-                console.log("无卡片提醒-1", resultObj.errorMsg);
+                // console.log("无卡片提醒-1", resultObj.errorMsg);
                 //无卡片提醒
                 // that.closeSFZ();
               }
@@ -2250,6 +2250,18 @@
       roleIds.forEach((roleId) => {
         getRoleDetail(roleId).then((res) => {
           var roleAlias = res.data.data.roleAlias;
+          if (roleAlias == "保安公司管理员") {
+            that.option.group[1].column[4].dicData = [
+              {
+                label: "是",
+                value: "1",
+              },
+              {
+                label: "否",
+                value: "2",
+              },
+            ];
+          }
           if (
             roleAlias == "保安公司管理员" ||
             roleAlias == "保安" ||

--
Gitblit v1.9.3