From 44d89f2faf9498c0b982613bef7294f83c854e88 Mon Sep 17 00:00:00 2001
From: qushaowei <qushaowei@163.com>
Date: 星期三, 31 一月 2024 17:50:04 +0800
Subject: [PATCH] Merge branch 'master' of http://117.34.109.166:18448/r/vue_mdc_430 into develop

---
 src/views/mdc/base/EquipmentList.vue                               |   18 ++++-
 src/views/system/UserList.vue                                      |   10 ++
 src/views/system/WorkshopSignageManagement.vue                     |   27 +++++++--
 src/views/system/modules/PasswordModal.vue                         |   12 +++-
 src/views/system/modules/UserRoleModal.vue                         |   10 ++
 src/views/system/modules/RoleModal.vue                             |   10 ++
 src/views/system/modules/UserRecycleBinModal.vue                   |   16 ++++-
 src/mixins/JeecgListMixin.js                                       |   18 +++++-
 src/views/system/modules/ProductionManager/ProductionEquipment.vue |    6 +
 src/views/system/modules/WorkshopModal.vue                         |   13 +++
 10 files changed, 111 insertions(+), 29 deletions(-)

diff --git a/src/mixins/JeecgListMixin.js b/src/mixins/JeecgListMixin.js
index 841a3e7..b5986e5 100644
--- a/src/mixins/JeecgListMixin.js
+++ b/src/mixins/JeecgListMixin.js
@@ -358,11 +358,19 @@
               )
             })
           } else {
-            this.$message.success(info.file.response.message || `${info.file.name} 鏂囦欢涓婁紶鎴愬姛`)
+            // this.$message.success(info.file.response.message || `${info.file.name} 鏂囦欢涓婁紶鎴愬姛`)
+            this.$notification.success({
+              message:'娑堟伅',
+              description:info.file.response.message || `${info.file.name} 鏂囦欢涓婁紶鎴愬姛`
+            });
           }
           this.loadData()
         } else {
-          this.$message.error(`${info.file.name} ${info.file.response.message}.`);
+          // this.$message.error(`${info.file.name} ${info.file.response.message}.`);
+          this.$notification.error({
+            message:'娑堟伅',
+            description:`${info.file.name} ${info.file.response.message}.`
+          });
         }
       } else if (info.file.status === 'error') {
         this.loading = false;
@@ -384,7 +392,11 @@
             })
           }
         } else {
-          this.$message.error(`鏂囦欢涓婁紶澶辫触: ${info.file.msg} `);
+          // this.$message.error(`鏂囦欢涓婁紶澶辫触: ${info.file.msg} `);
+          this.$notification.error({
+            message:'娑堟伅',
+            description:`鏂囦欢涓婁紶澶辫触: ${info.file.msg} `
+          });
         }
       }
     },
diff --git a/src/views/mdc/base/EquipmentList.vue b/src/views/mdc/base/EquipmentList.vue
index c2b147a..cee4b26 100644
--- a/src/views/mdc/base/EquipmentList.vue
+++ b/src/views/mdc/base/EquipmentList.vue
@@ -22,8 +22,8 @@
 
           <a-col :md="6" :sm="8">
             <a-form-item label="杞﹂棿鍚嶇О">
-              <!--<a-input placeholder="璇疯緭鍏ヨ处鍙锋煡璇�" v-model="queryParam.username"></a-input>-->
-              <a-input placeholder="璇疯緭鍏ヨ溅闂村悕绉�" v-model="queryParam.productionName"></a-input>
+              <!--<a-input placeholder="璇疯緭鍏ヨ溅闂村悕绉�" v-model="queryParam.productionName"></a-input>-->
+              <a-tree-select v-model="queryParam.productionName" :treeData="workshopTreeData" placeholder="璇烽�夋嫨杞﹂棿"  tree-default-expand-all></a-tree-select>
             </a-form-item>
           </a-col>
 
@@ -38,6 +38,7 @@
     <!-- 鎿嶄綔鎸夐挳鍖哄煙 -->
     <div class="table-operator" style="border-top: 5px">
       <a-button @click="handleAdd" type="primary" icon="plus" >娣诲姞璁惧</a-button>
+      <a-button type="primary" icon="download" @click="handleExportXls('璁惧淇℃伅')">瀵煎嚭</a-button>
       <a-dropdown v-if="selectedRowKeys.length > 0">
         <a-menu slot="overlay" @click="handleMenuClick">
           <a-menu-item key="1">
@@ -147,6 +148,7 @@
   import UserRecycleBinModal from './modules/EquipmentList/UserRecycleBinModal'
   import JSuperQuery from '@/components/jeecg/JSuperQuery'
   import JThirdAppButton from '@/components/jeecgbiz/thirdApp/JThirdAppButton'
+  import { queryProductionTreeList } from '@/api/api'
   import {mapActions} from 'vuex'
 
   export default {
@@ -256,10 +258,11 @@
           list: "/mdc/mdcEquipment/list",
           delete: "/mdc/mdcEquipment/delete",
           deleteBatch: "/mdc/mdcEquipment/deleteBatch",
-          // exportXlsUrl: "/sys/user/exportXls",
+          exportXlsUrl: "/mdc/mdcEquipment/exportXls",
           // importExcelUrl: "sys/user/importExcel",
         },
-        isDepartType:''
+        isDepartType:'',
+        workshopTreeData:[]
       }
     },
     computed: {
@@ -269,6 +272,7 @@
     },
     created() {
       this.queryTreeData()
+      this.getWorkshopListByApi()
     },
     methods: {
       ...mapActions(['QueryDepartTree']),
@@ -554,6 +558,12 @@
           this.loadData()
         }
       },
+
+      getWorkshopListByApi(){
+        queryProductionTreeList().then(res=>{
+          if(res.success) this.workshopTreeData=res.result
+        })
+      }
     }
 
   }
diff --git a/src/views/system/UserList.vue b/src/views/system/UserList.vue
index ef70a2b..9b4d5db 100644
--- a/src/views/system/UserList.vue
+++ b/src/views/system/UserList.vue
@@ -535,10 +535,16 @@
         }
         frozenBatch({ids: id, status: status}).then((res) => {
           if (res.success) {
-            that.$message.success(res.message);
+            that.$notification.success({
+              message:'娑堟伅',
+              description:res.message
+            });
             that.loadData();
           } else {
-            that.$message.warning(res.message);
+            that.$notification.warning({
+              message:'娑堟伅',
+              description:res.message
+            });
           }
         });
       },
diff --git a/src/views/system/WorkshopSignageManagement.vue b/src/views/system/WorkshopSignageManagement.vue
index 6c68353..380e6d3 100644
--- a/src/views/system/WorkshopSignageManagement.vue
+++ b/src/views/system/WorkshopSignageManagement.vue
@@ -7,7 +7,7 @@
           <!-- 鎼滅储鍖哄煙 -->
           <a-form layout="inline" @keyup.enter.native="searchQuery">
             <a-row :gutter="24">
-              <a-col :md="6" :sm="6">
+              <a-col :md="8" :sm="8">
                 <a-form-item label="杞﹂棿鍚嶇О" :labelCol="{ span: 5 }" :wrapperCol="{ span: 19}">
                   <a-input placeholder="" v-model="queryParam.workshopName"></a-input>
                 </a-form-item>
@@ -375,16 +375,25 @@
      */
     handleDelete2: function (equipmentId) {
       if (!this.url.delete2) {
-        this.$message.error('璇疯缃畊rl.delete2灞炴��!')
+        this.$notification.error({
+          message:'娑堟伅',
+          description:'璇疯缃畊rl.delete2灞炴��!'
+        });
         return
       }
       var that = this
       deleteAction(that.url.delete2, { workshopId: this.currentWorkshopId, equipmentId }).then((res) => {
         if (res.success) {
-          that.$message.success(res.message)
+          that.$notification.success({
+            message:'娑堟伅',
+            description:res.message
+          });
           that.loadData2()
         } else {
-          that.$message.warning(res.message)
+          that.$notification.warning({
+            message:'娑堟伅',
+            description:res.message
+          });
         }
       })
     },
@@ -446,9 +455,15 @@
       postAction(this.url.addDeviceInWorkshop, params).then((res) => {
         if (res.success) {
           this.loadData2()
-          this.$message.success(res.message)
+          this.$notification.success({
+            message:'娑堟伅',
+            description:res.message
+          });
         } else {
-          this.$message.warning(res.message)
+          this.$notification.warning({
+            message:'娑堟伅',
+            description:res.message
+          });
         }
       })
     },
diff --git a/src/views/system/modules/PasswordModal.vue b/src/views/system/modules/PasswordModal.vue
index 810cc5f..ed45ce5 100644
--- a/src/views/system/modules/PasswordModal.vue
+++ b/src/views/system/modules/PasswordModal.vue
@@ -105,11 +105,17 @@
             this.confirmLoading = true;
             let formData = Object.assign(this.model, values);
             changePassword(formData).then((res)=>{
-              if(res.success){
-                this.$message.success(res.message);
+              if(res.success){;
+                this.$notification.success({
+                  message:'娑堟伅',
+                  description:res.message
+                });
                 this.$emit('ok');
               }else{
-                this.$message.warning(res.message);
+                this.$notification.warning({
+                  message:'娑堟伅',
+                  description:res.message
+                });
               }
             }).finally(() => {
               this.confirmLoading = false;
diff --git a/src/views/system/modules/ProductionManager/ProductionEquipment.vue b/src/views/system/modules/ProductionManager/ProductionEquipment.vue
index 975697a..6227bb9 100644
--- a/src/views/system/modules/ProductionManager/ProductionEquipment.vue
+++ b/src/views/system/modules/ProductionManager/ProductionEquipment.vue
@@ -254,10 +254,12 @@
 
         postAction(this.url.removeEquipmentForDepart,qs.stringify({productionId:this.productionId,equipmentId:equipmentId})).then((res)=>{
           if (res.success) {
-            this.$message.warning(res.message)
+            this.$notification.success({
+              message:'娑堟伅',
+              description:res.message
+            });
             this.loadData(this.productionId);
           }else{
-            // this.$message.warning(res.message)
             this.$notification.warning({
               message:'娑堟伅',
               description:res.message
diff --git a/src/views/system/modules/RoleModal.vue b/src/views/system/modules/RoleModal.vue
index a16e5e9..b990085 100644
--- a/src/views/system/modules/RoleModal.vue
+++ b/src/views/system/modules/RoleModal.vue
@@ -94,10 +94,16 @@
             }
             obj.then((res)=>{
               if(res.success){
-                that.$message.success(res.message);
+                that.$notification.success({
+                  message:'娑堟伅',
+                  description:res.message
+                });
                 that.$emit('ok');
               }else{
-                that.$message.warning(res.message);
+                that.$notification.warning({
+                  message:'娑堟伅',
+                  description:res.message
+                });
               }
             }).finally(() => {
               that.confirmLoading = false;
diff --git a/src/views/system/modules/UserRecycleBinModal.vue b/src/views/system/modules/UserRecycleBinModal.vue
index 921a3ed..a5ce0f1 100644
--- a/src/views/system/modules/UserRecycleBinModal.vue
+++ b/src/views/system/modules/UserRecycleBinModal.vue
@@ -145,7 +145,11 @@
               if(res.success){
                 this.handleOk()
                 this.handleClearSelection()
-                this.$message.success(`杩樺師 ${userIds.length} 涓敤鎴锋垚鍔燂紒`)
+                // this.$message.success(`杩樺師 ${userIds.length} 涓敤鎴锋垚鍔燂紒`)
+                this.$notification.success({
+                  message:'娑堟伅',
+                  description:`杩樺師 ${userIds.length} 涓敤鎴锋垚鍔燂紒`
+                });
               }
             })
           }
@@ -166,9 +170,15 @@
               if (res.success) {
                 this.loadData()
                 this.handleClearSelection()
-                this.$message.success(`褰诲簳鍒犻櫎 ${userIds.length} 涓敤鎴锋垚鍔燂紒`)
+                that.$notification.success({
+                  message:'娑堟伅',
+                  description:`褰诲簳鍒犻櫎 ${userIds.length} 涓敤鎴锋垚鍔燂紒`
+                });
               } else {
-                that.$message.warning(res.message);
+                that.$notification.warning({
+                  message:'娑堟伅',
+                  description:res.message
+                });
               }
             });
           },
diff --git a/src/views/system/modules/UserRoleModal.vue b/src/views/system/modules/UserRoleModal.vue
index 04143f0..7fea329 100644
--- a/src/views/system/modules/UserRoleModal.vue
+++ b/src/views/system/modules/UserRoleModal.vue
@@ -146,13 +146,19 @@
         console.log("璇锋眰鍙傛暟锛�",params);
         saveRolePermission(params).then((res)=>{
           if(res.success){
-            that.$message.success(res.message);
+            that.$notification.success({
+              message:'娑堟伅',
+              description:res.message
+            });
             that.loading = false;
             if (exit) {
               that.close()
             }
           }else {
-            that.$message.error(res.message);
+            that.$notification.warning({
+              message:'娑堟伅',
+              description:res.message
+            });
             that.loading = false;
             if (exit) {
               that.close()
diff --git a/src/views/system/modules/WorkshopModal.vue b/src/views/system/modules/WorkshopModal.vue
index 0164db1..2118a6d 100644
--- a/src/views/system/modules/WorkshopModal.vue
+++ b/src/views/system/modules/WorkshopModal.vue
@@ -21,6 +21,9 @@
         <a-form-model-item label="璁惧缂栧彿棰滆壊">
           <a-input type="color" v-model="model.equipmentIdColor"></a-input>
         </a-form-model-item>
+        <a-form-model-item label="鎺堟潈鏍囪瘑">
+          <a-input placeholder="璇疯緭鍏ユ巿鏉冩爣璇�" v-model="model.perms"/>
+        </a-form-model-item>
       </a-form-model>
     </a-spin>
   </a-modal>
@@ -99,10 +102,16 @@
             }
             obj.then((res) => {
               if (res.success) {
-                that.$message.success(res.message)
+                that.$notification.success({
+                  message:'娑堟伅',
+                  description:res.message
+                });
                 that.$emit('ok')
               } else {
-                that.$message.warning(res.message)
+                that.$notification.warning({
+                  message:'娑堟伅',
+                  description:res.message
+                });
               }
             }).finally(() => {
               that.confirmLoading = false

--
Gitblit v1.9.3