From 9b825939b7f0a7439d704b379812362dd95697fc Mon Sep 17 00:00:00 2001
From: loulijun2021 <1694218219@qq.com>
Date: 星期一, 11 七月 2022 17:49:26 +0800
Subject: [PATCH] 1.优化代码2.修改实施部提出的bug3.生产开报工外协列表自动弹窗实现部分

---
 src/views/jcsz/jsqd.vue |   47 +++++++++++++++++++++++++++++++++++------------
 1 files changed, 35 insertions(+), 12 deletions(-)

diff --git a/src/views/jcsz/jsqd.vue b/src/views/jcsz/jsqd.vue
index 7226df7..3c2a826 100644
--- a/src/views/jcsz/jsqd.vue
+++ b/src/views/jcsz/jsqd.vue
@@ -23,6 +23,7 @@
                 filterable
                 style="width: 200px"
                 placeholder="璇烽�夋嫨"
+                @focus="getRoleTypeSearch2"
               >
                 <el-option
                   v-for="item in RoleTypeCodeArr2"
@@ -53,8 +54,9 @@
         <el-table
           :data="tableData"
           border
+
           stripe
-          :height="tableHeight"
+          :height="tableHeight+'px'"
           :style="{width: 100+'%',height:tableHeight+'px'}"
           highlight-current-row
           :header-cell-style="this.$headerCellStyle"
@@ -309,6 +311,7 @@
               :options="StuOrgArr"
               :props="defaultProps"
               style="width: 200px;"
+              @focus="getUserOrganization"
               @change="dialogCascaderChange"
             />
 
@@ -509,7 +512,7 @@
 
 const SER_HZ = /^[\u4e00-\u9fa5]+$/
 export default {
-  name: 'Zzjg',
+  name: 'JSQD',
   components: {
     Pagination
   },
@@ -632,8 +635,8 @@
   },
   created() {
     this.getRoleSearch()
-    this.getRoleTypeSearch2()
-    this.getUserOrganization()
+    // this.getRoleTypeSearch2()
+    // this.getUserOrganization()
   },
   mounted() {
     window.addEventListener('resize', this.getHeight)
@@ -790,7 +793,7 @@
         console.log(window.innerHeight)
         this.mainHeight = window.innerHeight - 250
         this.tableHeight = this.mainHeight - 100
-        this.isFullscreen = window.innerHeight < 800
+        // this.isFullscreen = window.innerHeight < 800
       })
     },
     /* 璁剧疆妯″潡*/
@@ -990,7 +993,7 @@
         pcIsSelected2 = true
 
         const interval = setInterval(() => {
-          if ($('input:checkbox').length > 0) {
+          if ($("input[name='PC']").length > 0) {
             waitFlag = true
           }
           if (waitFlag) {
@@ -1010,7 +1013,7 @@
         appIsSelected2 = true
 
         const interval = setInterval(() => {
-          if ($('input:checkbox').length > 0) {
+          if ($("input[name='APP']").length > 0) {
             waitFlag = true
           }
           if (waitFlag) {
@@ -1031,7 +1034,7 @@
         appIsSelected2 = true
 
         const interval = setInterval(() => {
-          if ($('input:checkbox').length > 0) {
+          if ($("input[name='PC']").length > 0) {
             waitFlag = true
           }
           if (waitFlag) {
@@ -1250,12 +1253,20 @@
       const currentCode = this.dialogFormRight.rightCurrentCode// 鏉冮檺鎿嶄綔绔痗ode
       // 1.绗竴绉嶆儏鍐�  鍗婂彾涓洪浂  鍏ㄥ彾涓洪浂
       if (checkedKeys.length === 0 && halfCheckedKeys.length === 0) {
-        console.log('1.绗竴绉嶆儏鍐�  鍗婂彾涓洪浂  鍏ㄥ彾涓洪浂')
+        console.log('1.绗竴绉嶆儏鍐�  鍗婂彾涓洪浂  鍏ㄥ彾涓洪浂1111')
         this.dialogFormRight.rightOperationArr.forEach((item, index) => {
           if (item.code === currentCode) {
             item.isSelected2 = false
+
             this.$nextTick(() => {
-              $('input:checkbox').eq(index).prop('checked', false)// 鑷畾涔夊崟閫夋鍥炴樉
+              if (item.name === 'PC') {
+                $("input[name='PC']").eq(0).prop('checked', false)// 鑷畾涔夊崟閫夋鍥炴樉
+              }
+              if (item.name === 'APP') {
+                $("input[name='APP']").eq(0).prop('checked', false)// 鑷畾涔夊崟閫夋鍥炴樉
+              }
+              // $("input[name='APP']").eq(0).prop('checked', false)// 鑷畾涔夊崟閫夋鍥炴樉
+              // $('input:checkbox').eq(index).prop('checked', false)// 鑷畾涔夊崟閫夋鍥炴樉
             })
           }
         })
@@ -1274,7 +1285,13 @@
           if (item.code === currentCode) {
             item.isSelected2 = true
             this.$nextTick(() => {
-              $('input:checkbox').eq(index).prop('checked', true)// 鑷畾涔夊崟閫夋鍥炴樉
+              if (item.name === 'PC') {
+                $("input[name='PC']").eq(0).prop('checked', true)// 鑷畾涔夊崟閫夋鍥炴樉
+              }
+              if (item.name === 'APP') {
+                $("input[name='APP']").eq(0).prop('checked', true)// 鑷畾涔夊崟閫夋鍥炴樉
+              }
+              // $('input:checkbox').eq(index).prop('checked', true)// 鑷畾涔夊崟閫夋鍥炴樉
             })
           }
         })
@@ -1294,7 +1311,13 @@
           if (item.code === currentCode) {
             item.isSelected2 = true
             this.$nextTick(() => {
-              $('input:checkbox').eq(index).prop('checked', true)// 鑷畾涔夊崟閫夋鍥炴樉
+              if (item.name === 'PC') {
+                $("input[name='PC']").eq(0).prop('checked', true)// 鑷畾涔夊崟閫夋鍥炴樉
+              }
+              if (item.name === 'APP') {
+                $("input[name='APP']").eq(0).prop('checked', true)// 鑷畾涔夊崟閫夋鍥炴樉
+              }
+              // $('input:checkbox').eq(index).prop('checked', true)// 鑷畾涔夊崟閫夋鍥炴樉
             })
           }
         })

--
Gitblit v1.9.3