From 00062ed2e07d3d705abd1baa10ee483617f10dfb Mon Sep 17 00:00:00 2001 From: ludc Date: 星期五, 09 六月 2023 18:44:57 +0800 Subject: [PATCH] 提交get请求中文编码问题,表名常量类,表别名枚举类 --- Source/UBCS-WEB/src/views/code/code.vue | 40 ++++++++++++++++++++++------------------ 1 files changed, 22 insertions(+), 18 deletions(-) diff --git a/Source/UBCS-WEB/src/views/code/code.vue b/Source/UBCS-WEB/src/views/code/code.vue index 9016174..5b3a5ea 100644 --- a/Source/UBCS-WEB/src/views/code/code.vue +++ b/Source/UBCS-WEB/src/views/code/code.vue @@ -1173,7 +1173,6 @@ refreshParentClassifyDataChange() { this.parentClassifyOnLoad(this.parentClsfyParams.parentClassifyDataPage, this.parentClsfyParams.parentClassifyQuery); }, - // TODO:寰呬慨鏀� parentClassifyOnLoad(page, params = {}) { let parentClsParam = this.parentClsfyParams; parentClsParam.classifyDialogLoading = true; @@ -1204,22 +1203,25 @@ loadlistClassifyLinkAttr() { let attrParam = this.selectAttrParams; //console.log(this.currentSelectTreeData); - attrParam.selectAttrOptionLoading = true; + this.selectAttrParams.selectAttrOptionLoading = true; let conditionMaps = {}; if(attrParam.selectAttrQeury){ Object.keys(attrParam.selectAttrQeury).forEach(key=>{ - conditionMaps['conditionMap['+key+']'] = attrParam.selectAttrQeury[key]; + conditionMaps['conditionMap['+key+']'] = attrParam.selectAttrQeury[key].trim(); }); } conditionMaps['conditionMap[codeClassifyOid]'] = this.currentSelectTreeData.oid; conditionMaps['conditionMap[btmTypeOid]'] = this.currentSelectTreeData.btmTypeOid; listClassifyLinkAttr(conditionMaps).then(res=>{ - //console.log(res.data.data); - attrParam.selectAttrData = res.data.data; - attrParam.selectAttrOptionLoading = false; + const data = res.data; this.$nextTick(() => { - this.$refs[attrParam.ref].doLayout() + this.$refs[attrParam.ref].doLayout() }); + //console.log(data.data); + this.selectAttrParams.selectAttrData = data.data; + this.selectAttrParams.selectAttrOptionLoading = false; + // 灏嗘悳绱㈡鍐呭缃┖ + this.selectAttrParams.selectAttrQeury = {}; }) }, // 鐐瑰嚮鎼滅储鍚庤Е鍙戣浜嬩欢 @@ -1899,7 +1901,7 @@ //瀛樺偍褰撳墠鍏宠仈鐨勭紪鐮佽鍒欑浉鍏充俊鎭� this.currentCodeRuleOid = row.oid; this.currentRuleLcStatus = row.lcStatus; - this.sendGridCodeBasicSec({"pkCodeRule_equal":row.oid},false); + this.sendGridCodeBasicSec({"cpkCodeRule":row.oid},false); }, // 鍙戦�佸姞杞藉熀纭�鐮佹鐨勮姹� sendGridCodeBasicSec(condition,isAdancedQuery/** 鏄惁楂樼骇鏌ヨ */){ @@ -1910,11 +1912,11 @@ let conditionMaps = {}; if(condition && !isAdancedQuery){ Object.keys(condition).forEach(key=>{ - conditionMaps['conditionMap[t.'+key+']'] = condition[key]; + conditionMaps['conditionMap[pl_code_basicsec.'+key+']'] = condition[key].trim(); }); } if(isAdancedQuery){ - condition['conditionMap[t.pkCodeRule_equal]'] = this.currentCodeRuleOid == null || this.currentCodeRuleOid == '' + condition['conditionMap[pl_code_basicsec.pkCodeRule]'] = this.currentCodeRuleOid == null || this.currentCodeRuleOid == '' ? this.selectionList[0].oid:this.currentCodeRuleOid; } gridCodeBasicSec(1, -1,isAdancedQuery ? condition:conditionMaps).then(res => { @@ -1945,11 +1947,11 @@ }, basicSearchChange(params, done){ //console.log(this.$refs.crudBasic); - this.sendGridCodeBasicSec(Object.assign(params,{"pkCodeRule_equal":this.selectionList[this.selectionList.length-1].oid}),false); + this.sendGridCodeBasicSec(Object.assign(params,{"pkCodeRule":this.selectionList[this.selectionList.length-1].oid}),false); done(); }, basicSearchReset(){ - this.sendGridCodeBasicSec({"pkCodeRule_equal":this.selectionList[this.selectionList.length-1].oid},false); + this.sendGridCodeBasicSec({"pkCodeRule":this.selectionList[this.selectionList.length-1].oid},false); }, // 涓婄Щ涓嬬Щ鍩虹鐮佹 upOrderNum(row){ @@ -2055,7 +2057,7 @@ fieldType: 'combox', queryField: 'lcStatus', comboxKey: 'codeSearchLCStatus', - } + }, ] }else { this.advancedQueryParam.options = [ @@ -2063,22 +2065,22 @@ data: [], title: '鐮佹缂栧彿', fieldType: 'text', - queryField: 't.id', + queryField: 'pl_code_basicsec.id', },{ data: [], title: '鐮佹鍚嶇О', fieldType: 'text', - queryField: 't.name', + queryField: 'pl_code_basicsec.name', },{ data: [], title: '鎻忚堪', fieldType: 'text', - queryField: 't.description', + queryField: 'pl_code_basicsec.description', },{ data: [], title: '鐮佹绫诲瀷', fieldType: 'combox', - queryField: 't.secType', + queryField: 'pl_code_basicsec.secType', comboxKey: 'codeSecType', } ] @@ -2355,11 +2357,13 @@ searchChange(params, done) { this.page.currentPage = 1; // 澶氫釜conditionMap杩欐牱浼犲弬锛屽揩閫熸煡璇㈤粯璁ら噰鐢ㄦā绯婃煡璇� + let requestData = {}; if(params){ Object.keys(params).forEach(key=>{ - this.query['conditionMap['+key+'_like]'] = params[key]; + requestData["conditionMap"+'['+key+']'] = params[key].trim(); }); } + this.query = requestData; this.onLoad(this.page); done(); }, -- Gitblit v1.9.3