From 9be2e2f91332ed341406acf9739d8912dddbf6fe Mon Sep 17 00:00:00 2001 From: zhaowei <zhaowei> Date: 星期二, 22 七月 2025 20:43:43 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/master' --- src/views/eam/equipment/modules/LxSearchEquipmentSelect.vue | 20 +++++++++++++++++--- 1 files changed, 17 insertions(+), 3 deletions(-) diff --git a/src/views/eam/equipment/modules/LxSearchEquipmentSelect.vue b/src/views/eam/equipment/modules/LxSearchEquipmentSelect.vue index b5c223c..ec840e2 100644 --- a/src/views/eam/equipment/modules/LxSearchEquipmentSelect.vue +++ b/src/views/eam/equipment/modules/LxSearchEquipmentSelect.vue @@ -47,6 +47,11 @@ type:Boolean, default:()=>true, required:false + }, + factoryOrgCode:{ + type:String, + default:'', + required:false } }, data() { @@ -74,13 +79,20 @@ this.initSelectValue() } } + }, + factoryOrgCode:{ + handler(val){ + if(val){ + this.loadData() + } + } } }, methods: { initSelectValue() { if(!this.selectedAsyncValue || !this.selectedAsyncValue.key || this.selectedAsyncValue.key!=this.value){ console.log("杩欐墠璇锋眰鍚庡彴") - getAction(`/eam/equipment/asyncLoadEquipment`, { id: this.value }).then(res=>{ + getAction(`/eam/equipment/asyncLoadEquipment`, { id: this.value,factoryOrgCode:this.factoryOrgCode }).then(res=>{ if(res.success){ if(res.result && res.result.length > 0){ let obj = { @@ -101,7 +113,7 @@ this.options = [] this.loading = true // 瀛楀吀code鏍煎紡锛歵able,text,code - getAction(`/eam/equipment/asyncLoadEquipment`, { keyword: value, pageSize: this.pageSize }).then(res => { + getAction(`/eam/equipment/asyncLoadEquipment`, { keyword: value, pageSize: this.pageSize,factoryOrgCode:this.factoryOrgCode }).then(res => { this.loading = false if (res.success) { if (currentLoad != this.lastLoad) { @@ -119,7 +131,7 @@ initDictData() { //寮傛涓�寮�濮嬩篃鍔犺浇涓�鐐规暟鎹� this.loading = true - getAction(`/eam/equipment/asyncLoadEquipment`, { pageSize: this.pageSize, keyword: '' }).then(res => { + getAction(`/eam/equipment/asyncLoadEquipment`, { pageSize: this.pageSize, keyword: '' ,factoryOrgCode:this.factoryOrgCode}).then(res => { this.loading = false if (res.success) { this.options = [...res.result] @@ -137,12 +149,14 @@ this.selectedAsyncValue = selectedObj //update-begin---author:wangshuai ---date:20221115 for锛歔issues/4213]JSearchSelectTag鏀归�犳敮鎸佸閫�------------ this.selectedValue = selectedObj.key + this.$emit('autocompleteForm', this.options.find(item => item.equipmentId === selectedObj.value)) //update-end---author:wangshuai ---date:20221115 for锛歔issues/4213]JSearchSelectTag鏀归�犳敮鎸佸閫�------------ } else { this.selectedAsyncValue = undefined this.selectedValue = undefined this.options = [] this.loadData('') + this.$emit('autocompleteForm', {}) } this.callback() //update-end-author:scott date:20201222 for:銆愭悳绱€�戞悳绱㈡煡璇㈢粍浠讹紝鍒犻櫎鏉′欢锛岄粯璁や笅鎷夎繕鏄笂娆$殑缂撳瓨鏁版嵁锛屼笉濂� JT-191 -- Gitblit v1.9.3