From 0365fc08606d1308b8a81258410c3feb4da0fa7d Mon Sep 17 00:00:00 2001
From: ludc
Date: 星期三, 10 五月 2023 18:33:27 +0800
Subject: [PATCH] 修改属性命令,修改code界面中出现的bug
---
Source/UBCS-WEB/src/views/code/code.vue | 51 ++++++++++++++++++++++++++++++++++++++-------------
1 files changed, 38 insertions(+), 13 deletions(-)
diff --git a/Source/UBCS-WEB/src/views/code/code.vue b/Source/UBCS-WEB/src/views/code/code.vue
index 89dd072..759e0ee 100644
--- a/Source/UBCS-WEB/src/views/code/code.vue
+++ b/Source/UBCS-WEB/src/views/code/code.vue
@@ -202,6 +202,9 @@
ref="crudBasic"
:table-loading="loadingBasic"
:data="basicData"
+ @row-click="codeBasicSecRowClick"
+ @search-change="basicSearchChange"
+ @search-reset="basicSearchReset"
:permission="permissionList"
@selection-change="selectionBasicChange"
@refresh-change="refreshChangeBasicSec">
@@ -600,7 +603,7 @@
placeholder="璇烽�夋嫨"
prefix-icon="el-icon-search"
readonly="true"
- v-model="form.parentClassifySecOid"
+ v-model="form.parentClassifySecText"
@focus="openAttrSelectOrGetValue('parentClassifySecOid')"
:disabled="basicSecOnlyRead">
<i slot="suffix" class="el-icon-circle-close" @click="clearAttrDataByIcon('parentClassifySecOid')" style="margin-right: 5px;cursor: pointer;"></i>
@@ -894,7 +897,7 @@
},
classisyValueTreeOption: classisyValueTreeOption, //鍒嗙被鐮佹鏍戠浉鍏抽厤缃」
classifyValueTreeData: [],
- currentSelectTreeData: '', //褰撳墠閫変腑鐨勫垎绫荤爜鍊兼爲鑺傜偣
+ //currentSelectClsValueTreeData: '', //褰撳墠閫変腑鐨勫垎绫荤爜鍊兼爲鑺傜偣
/* 涓哄睘鎬ч�夊彇鍊肩獥鍙f樉绀烘墦寮�鎺у埗鍙橀噺 */
isShowSelectAttrOption: false,
@@ -1170,10 +1173,10 @@
saveSelectedParentClassify(){
//console.log(this.parentClassifySelectionList.length);
if(this.parentClassifySelectionList.length != 1){
- this.$message.warning("鍙兘閫夋嫨涓�鏉℃暟鎹�!");
+ this.$message.warning("璇烽�夋嫨涓�鏉℃暟鎹�!");
return false;
}
- //璋冪敤瀛愮粍浠跺苟浼犻�掑綋鍓嶉�変腑鐨勫弬鏁板�硷紝瀹炵幇鍥炴樉
+ //鍙傛暟鍊硷紝瀹炵幇鍥炴樉
this.form.parentClassifySecOid = this.parentClassifySelectionList[0].oid;
this.form.parentClassifySecText = this.parentClassifySelectionList[0].name;
//娓呯┖褰撳墠閫変腑鐨勮
@@ -1609,7 +1612,7 @@
/** 鍩虹鐮佹鐩稿叧鏂规硶 */
//闃叉鎵撳紑杩囩紪杈戠獥鍙d箣鍚庤〃鍗曚腑瀛樺湪鍊硷紝鎵�浠ラ渶瑕佹竻绌�,骞跺垵濮嬪寲form琛ㄥ崟灞炴��
clearBasicAddForm(){
- this.form = this.$options.data().form;;
+ this.form = this.$options.data().form;
// this.changeSectypeFormItems(null);
},
// 鎵撳紑鏂板绐楀彛
@@ -1903,9 +1906,12 @@
//瀛樺偍褰撳墠鍏宠仈鐨勭紪鐮佽鍒欑浉鍏充俊鎭�
this.currentCodeRuleOid = row.oid;
this.currentRuleLcStatus = row.lcStatus;
- gridCodeBasicSec(1, -1, {"pkCodeRule":row.oid}).then(res => {
+ this.sendGridCodeBasicSec({"pkCodeRule":row.oid});
+ },
+ // 鍙戦�佸姞杞藉熀纭�鐮佹鐨勮姹�
+ sendGridCodeBasicSec(condition){
+ gridCodeBasicSec(1, -1, condition).then(res => {
const data = res.data.data;
- // console.log(data);
if(this.cloneSettingBox){
this.cloneData = data.records;
// console.log(tihs.cloneData);
@@ -1920,7 +1926,23 @@
// 鍩虹鐮佹閫変腑鏃惰Е鍙�
selectionBasicChange(list) {
this.selectionBasicList = list;
+ this.$refs.crudBasic.setCurrentRow(this.selectionBasicList[list.length-1]);
//console.log(this.selectionBasicList);
+ },
+ // 鍩虹鐮佹琚崟鍑昏〃鏍艰鏃惰Е鍙�
+ codeBasicSecRowClick(row){
+ this.$refs.crudBasic.toggleSelection();
+ this.selectionBasicList = row;
+ this.$refs.crudBasic.setCurrentRow(row);
+ this.$refs.crudBasic.toggleRowSelection(row); //閫変腑褰撳墠琛�
+ },
+ basicSearchChange(params, done){
+ //this.$refs.crudBasic.tableOption.searchShow = false;
+ this.sendGridCodeBasicSec(Object.assign(params,{"pkCodeRule":this.selectionList[this.selectionList.length-1].oid}));
+ done();
+ },
+ basicSearchReset(){
+ this.sendGridCodeBasicSec({"pkCodeRule":this.selectionList[this.selectionList.length-1].oid});
},
// 涓婄Щ涓嬬Щ鍩虹鐮佹
upOrderNum(row){
@@ -1973,7 +1995,7 @@
this.loadBasic({"oid":this.currentCodeRuleOid == null || this.currentCodeRuleOid == '' ? this.selectionList[0].oid:this.currentCodeRuleOid});
},
-
+
/** 缂栫爜瑙勫垯鐩稿叧鏂规硶 */
// 鏌ヨ浣跨敤鑼冨洿
handleRange(){
@@ -2077,7 +2099,7 @@
codeOtherCloneRuleRowClick (row) {
this.loadBasic(row);
},
- // 缂栫爜瑙勫垯褰撳墠閫変腑琛屽彉鍖栫殑鏃跺�欒Е鍙�
+ // 浠庡叾浠栬鍒欏厠闅嗙爜娈电晫闈腑缂栫爜瑙勫垯褰撳墠閫変腑琛屽彉鍖栫殑鏃跺�欒Е鍙�
selectionOtherCloneCodeRuleChange(list) {
//console.log(list);
this.selectionOtherCloneCodeRuleList = list;
@@ -2152,7 +2174,6 @@
});
});
},
-
// 娣诲姞
rowSave(row, done, loading) {
add(row).then(() => {
@@ -2232,8 +2253,13 @@
// 缂栫爜瑙勫垯褰撳墠閫変腑琛屽彉鍖栫殑鏃跺�欒Е鍙�
selectionChange(list) {
this.selectionList = list;
- //console.log("selectionChange====="+list);
+ // console.log("selectionChange====="+list);
this.$refs.crud.setCurrentRow(this.selectionList[list.length-1]);
+ //褰撳墠閫変腑琛屼负绌虹殑鏃跺�欏氨灏嗙爜娈电鐞嗚〃鏍兼暟鎹疆绌�
+ if(list==''){
+ this.basicData = '';
+ console.log(this.$refs.crudBasic);
+ }
if(this.selectionList.length > 0){
this.currentCodeRuleOid = this.selectionList[list.length-1].oid;
this.currentRuleLcStatus = this.selectionList[list.length-1].lcStatus;
@@ -2264,7 +2290,7 @@
this.loading = false;
this.loadBasic(this.data[0])
this.$nextTick(() => {
- //this.$refs.crud.toggleRowSelection(this.data[0]);
+ this.$refs.crud.toggleRowSelection(this.data[0]);
this.$refs.crud.setCurrentRow(this.data[0]);
})
this.selectionList = data.records[0];
@@ -2289,7 +2315,6 @@
//this.$emit('openSelectreferConfig')
}
},
-
// 鐐瑰嚮杈撳叆妗嗙殑脳鍙凤紝娓呯┖杈撳叆妗嗕腑鐨勫唴瀹�
clearAttrDataByIcon(condition){
if(condition === 'attr'){
--
Gitblit v1.9.3