From 2c461eb9efb980d55dfd7407ee70088fc90a4a7a Mon Sep 17 00:00:00 2001
From: 钟日健 <5689795+arsn@user.noreply.gitee.com>
Date: Tue, 08 Feb 2022 14:24:31 +0800
Subject: [PATCH] 保安员详情修改

---
 src/views/exam/performance.vue |   89 ++++++++++++++++++++++++++------------------
 1 files changed, 53 insertions(+), 36 deletions(-)

diff --git a/src/views/exam/performance.vue b/src/views/exam/performance.vue
index fad79a9..94b2325 100644
--- a/src/views/exam/performance.vue
+++ b/src/views/exam/performance.vue
@@ -1,15 +1,26 @@
 /*
  * @Author: Morpheus
  * @Date: 2021-07-05 16:31:54
- * @Last Modified by: Morpheus
- * @Last Modified time: 2021-07-18 19:44:47
+ * @Last Modified by: liu
+ * @Last Modified time: 2021-11-23 14:17:22
  * menu-name 成绩管理
  */
 <template>
   <el-row class="morpheus-box">
-    <el-col :span="24" class="recruitmentManagement">
+    <el-col
+      :span="24"
+      :class="[
+        'recruitmentManagement',
+        $store.state.control.windowWidth >= 1024 ? 'oneRowSearch' : '',
+      ]"
+    >
       <el-card>
-        <div class="exam-card-body">
+        <div
+          :class="[
+            'exam-card-body',
+            $store.state.control.windowWidth >= 1024 ? 'oneRowSearch' : '',
+          ]"
+        >
           <avue-crud
             v-model="obj"
             class="company-box"
@@ -38,7 +49,15 @@
               {{ row.allGrade == -1 ? "" : row.allGrade }}
             </template>
             <template slot-scope="{ row }" slot="qualified">
-              {{ row.qualified == -1 ? "" : row.qualified==0?"合格":row.qualified==1?"不合格":'' }}
+              {{
+                row.qualified == -1
+                  ? ""
+                  : row.qualified == 0
+                  ? "合格"
+                  : row.qualified == 1
+                  ? "不合格"
+                  : ""
+              }}
             </template>
 
             <!-- 自定义按钮 -->
@@ -73,7 +92,7 @@
                 icon="el-icon-collection"
                 class="start-kaoshi"
                 v-if="permission.performance_print"
-                :disabled="row.qualified==1"
+                :disabled="row.qualified == 1"
                 @click="securityPrint(row)"
                 >保安证打印
               </el-button>
@@ -84,7 +103,6 @@
             title="实操成绩导入"
             append-to-body
             :visible.sync="excelBox"
-            
             width="555px"
           >
             <avue-form
@@ -113,7 +131,6 @@
 export default {
   data() {
     var validatePass = (rule, value, callback) => {
-      console.log(value);
       if (value == undefined || value == "") {
         callback(new Error("请输入实操成绩"));
         return;
@@ -158,7 +175,7 @@
         menu: true,
         menuWidth: 186,
         labelWidth: 120,
-
+        ...this.$store.state.control.clearOtherBut,
         column: [
           {
             label: "考试名称",
@@ -187,7 +204,7 @@
               },
             ],
             // overHidden: true,
-            width:230,
+            width: 230,
           },
           {
             label: "用户名",
@@ -214,7 +231,7 @@
                 trigger: "blur",
               },
             ],
-            width:160
+            width: 160,
           },
           {
             label: "所属公司",
@@ -246,7 +263,7 @@
                 trigger: "blur",
               },
             ],
-            width:250,
+            width: 250,
           },
           {
             label: "考试开始时间",
@@ -440,6 +457,7 @@
         pageSize: 10,
         currentPage: 1,
         total: 16,
+        ...this.$store.state.control.changePageSize,
       },
       questionBankQuery: {},
       questionBankSelectionList: [],
@@ -497,7 +515,7 @@
       },
     };
   },
-  computed:{
+  computed: {
     ...mapGetters(["userInfo", "permission"]),
     permissionList() {
       return {
@@ -519,31 +537,30 @@
       var roleIds = this.userInfo.role_id.split(",");
       roleIds.forEach((roleId) => {
         getRoleDetail(roleId).then((res) => {
-            var roleAlias = res.data.data.roleAlias;
-            if (
-              roleAlias == "保安公司管理员" ||
-              roleAlias == "保安" ||
-              roleAlias == "未持证保安"
-            ) {
-              //如果是保安公司管理员
-              params["deptId"] = that.userInfo.dept_id;
-            }
+          var roleAlias = res.data.data.roleAlias;
+          if (
+            roleAlias == "保安公司管理员" ||
+            roleAlias == "保安" ||
+            roleAlias == "未持证保安"
+          ) {
+            //如果是保安公司管理员
+            params["deptId"] = that.userInfo.dept_id;
+          }
+          that.questionBankLoading = false;
+          params["examType"] = 1;
+          getList(
+            page.currentPage,
+            page.pageSize,
+            Object.assign(params, this.query)
+          ).then((res) => {
+            const data = res.data.data;
+            that.questionBankPage.total = data.total;
+            that.questionBankData = data.records;
             that.questionBankLoading = false;
-            params["examType"] = 1;
-            getList(
-              page.currentPage,
-              page.pageSize,
-              Object.assign(params, this.query)
-            ).then((res) => {
-              const data = res.data.data;
-              that.questionBankPage.total = data.total;
-              that.questionBankData = data.records;
-              that.questionBankLoading = false;
-              that.questionBankSelectionClear();
-            });
-        })
+            that.questionBankSelectionClear();
+          });
+        });
       });
-      
     },
     questionBankSelectionClear() {
       this.questionBankSelectionList = [];

--
Gitblit v1.9.3