From 7aa9a5df273e2df95a7005a8a78004b684a53287 Mon Sep 17 00:00:00 2001 From: xiejun <xiejun@vci-tech.com> Date: 星期五, 12 一月 2024 09:26:16 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/master' --- Source/UBCS-WEB/src/views/docking/loge.vue | 3 Source/UBCS-WEB/src/views/integration/applicationForm.vue | 407 +++++++------- Source/UBCS-WEB/src/views/ruleBasic/delimiterConfig.vue | 2 Source/UBCS-WEB/src/views/ruleBasic/paddingCharacter.vue | 2 Source/UBCS-WEB/src/views/docking/info.vue | 3 Source/UBCS-WEB/src/components/FormTemplate/ThemeChildren.vue | 221 +++++++ Source/UBCS-WEB/src/views/integration/systemInfo.vue | 1 Source/UBCS-WEB/src/components/Theme/ThemeClassifyTreeform.vue | 487 +++-------------- Source/UBCS-WEB/src/components/Theme/ThemeClassifyTrees.vue | 540 ++++-------------- Source/UBCS-WEB/src/views/ruleBasic/usableCharacter.vue | 2 Source/UBCS-WEB/src/views/ruleBasic/prefixConfig.vue | 2 11 files changed, 646 insertions(+), 1,024 deletions(-) diff --git a/Source/UBCS-WEB/src/components/FormTemplate/ThemeChildren.vue b/Source/UBCS-WEB/src/components/FormTemplate/ThemeChildren.vue new file mode 100644 index 0000000..b5e4f9d --- /dev/null +++ b/Source/UBCS-WEB/src/components/FormTemplate/ThemeChildren.vue @@ -0,0 +1,221 @@ +<template> + <div v-if="dialogVisible"> + <el-dialog :before-close="EscHandlerClose" :title="dialogTitleName" :visible.sync="dialogVisible" append-to-body> + <template> + <el-select v-model="SelectValue" placeholder="璇烽�夋嫨" style="width: 135px"> + <el-option + v-for="item in SelectOption" + :key="item.value" + :label="item.label" + :value="item.value" + style="width: 150px"> + </el-option> + </el-select> + <el-input v-model="SelectSearchValue" placeholder="杈撳叆鍊煎悗杩涜妯$硦鏌ヨ" + style="width: 260px;margin-left: 15px"></el-input> + <el-button plain size="small" style="margin-left: 20px" type="primary" @click="SelectSearchHandler">鏌ヨ + </el-button> + </template> + <avue-crud :data="TableData" :option="this.codeType === 'btmCode' ? this.btmOption : this.option" @row-click="rowHandlerClick"> + <template slot="radio" slot-scope="{row}"> + <el-radio v-model="radioValue" :label="row.$index" style="padding-left: 10px !important;">{{ '' }} + </el-radio> + </template> + </avue-crud> + <div style="height: 30px"> + <div + style="display: inline-block;float: left;border: 1px solid #eeeeee;padding: 5px;margin-top: 5px;font-size: 14px "> + 宸茶缃殑鍊间负:[{{ this.TreeAddform[codeName] == '' ? '鏈缃��' : this.TreeAddform[codeName] }}] + </div> + <div style="padding-top: 10px;display: flex; justify-content: flex-end;float: right;overflow: hidden"> + <el-button size="small" type="primary" @click="HandlerClickSave">纭畾</el-button> + <el-button size="small" @click="HandlerClickEsc">鍙栨秷</el-button> + </div> + </div> + </el-dialog> + </div> +</template> + +<script> +import {defaultReferDataGrid, referDataGrid} from '@/api/MasterData/master' + +export default { + name: "ThemeChildren", + props: { + visible: { + type: Boolean, + default: false, + }, + SelectOption: { + type: Array, + }, + dialogTitle: { + type: String + }, + TreeAddform: { + type: Object + }, + codeName: { + type: String + }, + codeType: { + type: String + }, + codeLcstatus: { + type: String + } + }, + data() { + return { + SelectValue: 'id', + SelectSearchValue: '', + radioValue: '', + LineParm: {}, + crudName: '', + crudOid: '', + TableData: [], + option: { + addBtn: false, + index: true, + columnBtn: false, + refreshBtn: false, + border: true, + menu: false, + height: 380, + column: [ + { + label: '', + prop: 'radio', + width: 60, + display: false + }, + { + label: '鑻辨枃鍚嶇О', + prop: 'id' + }, + { + label: '涓枃鍚嶇О', + prop: 'name' + }, + { + label: '鎻忚堪', + prop: 'description' + } + ] + }, + btmOption:{ + addBtn: false, + index: true, + columnBtn: false, + refreshBtn: false, + border: true, + menu: false, + height:380, + column:[ + { + label: '', + prop: 'radio', + width: 60, + display: false + }, + { + label:'涓氬姟绫诲瀷缂栧彿', + prop:'id' + }, + { + label:'涓氬姟绫诲瀷鍚嶇О', + prop:'name' + }, + { + label:'鎻忚堪', + prop:'description' + } + ] + }, + } + }, + created() { + }, + mounted() { + }, + computed: { + dialogVisible: { + get() { + return this.visible; + }, + set(val) { + this.$emit("update:visible", val); + }, + }, + dialogTitleName() { + return `涓恒��${this.dialogTitle}銆戦�夊彇鍊糮; + }, + }, + methods: { + //鍏抽棴琛ㄥ崟 + EscHandlerClose() { + this.dialogVisible = false; + this.SelectSearchValue = ''; + this.SelectValue = 'id'; + this.radioValue = null; + this.LineParm = {}; + }, + // 妯$硦鏌ヨ + SelectSearchHandler() { + if (!this.SelectOption) { + return; // 濡傛灉SelectOption鏁版嵁涓嶅瓨鍦ㄧ洿鎺ヨ繑鍥� 閬垮厤鎶ラ敊 + } + + const Parameter = {}; + Parameter[`conditionMap['${this.SelectValue}']`] = this.SelectSearchValue; + + if(this.codeType === "btmCode"){ + this.btmDefaultRend(Parameter) + }else { + this.defaultSearchRend(Parameter); + } + }, + //琛ㄦ牸琛屽崟閫� + rowHandlerClick(row) { + this.radioValue = row.$index; + this.LineParm = row; + this.crudName = row.name; + this.crudOid = row.oid; + }, + //纭畾 + HandlerClickSave() { + if (Object.values(this.LineParm).length === 0) { + this.$message.warning('璇疯嚦灏戦�夋嫨涓�鏉℃暟鎹紒') + } else { + this.EscHandlerClose(); + this.$emit('defineHandler', { crudName: this.crudName, crudOid: this.crudOid ,codeType:this.codeType}); + } + }, + //鍙栨秷 + HandlerClickEsc() { + this.EscHandlerClose() + }, + //鎺ュ彛 + defaultSearchRend(Parameter) { + defaultReferDataGrid({ + referType: this.codeType, + isMuti: 'false', + 'conditionMap["lcstatus"]': this.codeLcstatus, + 'limit': '-1', + ...Parameter + }).then(res => { + this.TableData = res.data.records; + }) + }, + btmDefaultRend(Parameter) { + referDataGrid({valueField: 'id', isMuti: 'false', 'limit': '-1', ...Parameter}).then(res => { + this.TableData = res.data.data.records + }) + }, + } +} +</script> + +<style scoped> + +</style> diff --git a/Source/UBCS-WEB/src/components/Theme/ThemeClassifyTreeform.vue b/Source/UBCS-WEB/src/components/Theme/ThemeClassifyTreeform.vue index 5882a33..3219fe6 100644 --- a/Source/UBCS-WEB/src/components/Theme/ThemeClassifyTreeform.vue +++ b/Source/UBCS-WEB/src/components/Theme/ThemeClassifyTreeform.vue @@ -1,126 +1,57 @@ <template> <div> - <avue-form v-model="loneTreeNewForm" :option="option" v-if="flag == 'renonly'"> + <avue-form v-model="loneTreeNewForm" :option="renonlyOption" v-if="flag == 'renonly'"> </avue-form> - <avue-form v-model="loneTreeNewForm" :option="this.options" @submit="submits" v-else-if="flag == 'edit'"> + <avue-form v-model="loneTreeNewForm" :option="this.editOption" @submit="submits" v-else-if="flag == 'edit'"> </avue-form> <div> <!-- 缂栫爜瑙勫垯--> - <el-dialog :visible.sync="MasterdialogVisible" title="涓恒�愮紪鐮佽鍒欍�戦�夊彇鍊�" append-to-body :before-close="masterEscHandler"> - <template> - <el-select v-model="SelectValue" placeholder="璇烽�夋嫨" style="width: 135px"> - <el-option - v-for="item in SelectOption" - :key="item.value" - :label="item.label" - :value="item.value" - style="width: 150px"> - </el-option> - </el-select> - <el-input style="width: 260px;margin-left: 15px" placeholder="杈撳叆鍊煎悗杩涜妯$硦鏌ヨ" v-model="SelectFInd"></el-input> - <el-button size="small" type="primary" plain @click="SelectFindeHandler" style="margin-left: 20px">鏌ヨ</el-button> - </template> - <avue-crud :data="masterData" :option="attrOption" @row-click="masterSelect"> - <template slot="radio" slot-scope="{row}"> - <el-radio v-model="masterRow" :label="row.$index" style="padding-left: 10px !important;">{{ '' }} - </el-radio> - </template> - </avue-crud> - <div style="height: 30px"> - <div style="display: inline-block;float: left;border: 1px solid #eee;padding: 5px;margin-top: 5px;font-size: 14px " >宸茶缃殑鍊间负:[{{this.loneTreeNewForm.codeRuleOidName}}]</div> - <div style="padding-top: 10px;display: flex; justify-content: flex-end;float: right;overflow: hidden" > - <el-button type="primary" size="small" @click="MasterHandlerClick">纭畾</el-button> - <el-button size="small" @click="masterEscHandler">鍙栨秷</el-button> - </div> - </div> - </el-dialog> + <ThemeChildren + ref="ThemeMasterChildren" + dialogTitle="缂栫爜瑙勫垯" + codeName="codeRuleOidName" + codeType="coderule" + code-lcstatus="Released" + :visible.sync="MasterdialogVisible" + :SelectOption="SelectOption" + :TreeAddform="loneTreeNewForm" + @defineHandler="handlerDefine" + ></ThemeChildren> <!-- 鍏抽敭灞炴�ф煡璇㈣鍒�--> - <el-dialog :visible.sync="KeydialogVisible" title="涓恒�愬叧閿睘鎬ф煡璇㈣鍒欍�戦�夊彇鍊�" append-to-body :before-close="KeyEscHandler"> - <template> - <el-select v-model="SelectValue" placeholder="璇烽�夋嫨" style="width: 135px"> - <el-option - v-for="item in SelectOption" - :key="item.value" - :label="item.label" - :value="item.value" - style="width: 150px"> - </el-option> - </el-select> - <el-input style="width: 260px;margin-left: 15px" placeholder="杈撳叆鍊煎悗杩涜妯$硦鏌ヨ" v-model="SelectFInd"></el-input> - <el-button size="small" type="primary" plain @click="KeySelectFindeHandler" style="margin-left: 20px">鏌ヨ</el-button> - </template> - <avue-crud :data="KeyData" :option="attrOption" @row-click="KeySelect"> - <template slot="radio" slot-scope="{row}"> - <el-radio v-model="masterRow" :label="row.$index" style="padding-left: 10px !important;">{{ '' }} - </el-radio> - </template> - </avue-crud> - <div style="height: 30px"> - <div style="display: inline-block;float: left;border: 1px solid #eee;padding: 5px;margin-top: 5px;font-size: 14px " >宸茶缃殑鍊间负:[{{this.loneTreeNewForm.codeKeyAttrRepeatOidName}}]</div> - <div style="padding-top: 10px;display: flex; justify-content: flex-end;float: right;overflow: hidden" > - <el-button type="primary" size="small" @click="KeyHandlerClick">纭畾</el-button> - <el-button size="small" @click="KeyEscHandler">鍙栨秷</el-button> - </div> - </div> - </el-dialog> - <!-- 鐩镐技椤规煡璇㈣鍒�--> - <el-dialog :visible.sync="SimidialogVisible" title="涓恒�愮浉浼奸」鏌ヨ瑙勫垯銆戦�夊彇鍊�" append-to-body :before-close="simEscHandler"> - <template> - <el-select v-model="SelectValue" placeholder="璇烽�夋嫨" style="width: 135px"> - <el-option - v-for="item in SelectOption" - :key="item.value" - :label="item.label" - :value="item.value" - style="width: 150px"> - </el-option> - </el-select> - <el-input style="width: 260px;margin-left: 15px" placeholder="杈撳叆鍊煎悗杩涜妯$硦鏌ヨ" v-model="SelectFInd"></el-input> - <el-button size="small" type="primary" plain @click="SimSelectFindeHandler" style="margin-left: 20px">鏌ヨ</el-button> - </template> - <avue-crud :data="simData" :option="attrOption"@row-click="simSelect"> - <template slot="radio" slot-scope="{row}"> - <el-radio v-model="masterRow" :label="row.$index" style="padding-left: 10px !important;">{{ '' }} - </el-radio> - </template> - </avue-crud> - <div style="height: 30px"> - <div style="display: inline-block;float: left;border: 1px solid #eee;padding: 5px;margin-top: 5px;font-size: 14px " >宸茶缃殑鍊间负:[{{this.loneTreeNewForm.codeResembleRuleOidName}}]</div> - <div style="padding-top: 10px;display: flex; justify-content: flex-end;float: right;overflow: hidden" > - <el-button type="primary" size="small" @click="simHandlerClick">纭畾</el-button> - <el-button size="small" @click="simEscHandler">鍙栨秷</el-button> - </div> - </div> - </el-dialog> + <ThemeChildren + ref="ThemeKeyChildren" + :SelectOption="SelectOption" + :TreeAddform="loneTreeNewForm" + :visible.sync="KeydialogVisible" + code-lcstatus="Enabled" + codeName="codeKeyAttrRepeatOidName" + codeType="codekeyattrrepeat" + dialogTitle="鍏抽敭灞炴�ф煡璇㈣鍒�" + @defineHandler="handlerDefine" + ></ThemeChildren> + <!-- 鐩镐技椤规煡璇㈣鍒� codeResembleRuleOidName SimidialogVisible--> + <ThemeChildren + ref="ThemeSimChildren" + :SelectOption="SelectOption" + :TreeAddform="loneTreeNewForm" + :visible.sync="SimidialogVisible" + code-lcstatus="Enabled" + codeName="codeResembleRuleOidName" + codeType="coderesemblerule" + dialogTitle="鐩镐技椤规煡璇㈣鍒�" + @defineHandler="handlerDefine" + ></ThemeChildren> <!-- 瀛樺偍鐨勪笟鍔$被鍨�--> - <el-dialog :visible.sync="BtmdialogVisible" title="涓恒�愪笟鍔$被鍨嬨�戦�夊彇鍊�" append-to-body :before-close="BtmEscHandler"> - <template> - <el-select v-model="SelectValue" placeholder="璇烽�夋嫨" style="width: 135px !important;"> - <el-option - v-for="item in masterSelectOption" - :key="item.value" - :label="item.label" - :value="item.value" - style="width: 130px"> - </el-option> - </el-select> - <el-input style="width: 260px;margin-left: 15px" placeholder="杈撳叆鍊煎悗杩涜妯$硦鏌ヨ" v-model="SelectFInd"></el-input> - <el-button size="small" type="primary" plain @click="BtmSelectFindeHandler" style="margin-left: 20px">鏌ヨ</el-button> - </template> - <avue-crud :data="BtmData" :option="masterOption" @row-click="btmSelect"> - <template slot="radio" slot-scope="{row}"> - <el-radio v-model="masterRow" :label="row.$index" style="padding-left: 10px !important;">{{ '' }} - </el-radio> - </template> - </avue-crud> - <div style="height: 30px"> - <div style="display: inline-block;float: left;border: 1px solid #eee;padding: 5px;margin-top: 5px;font-size: 14px " >宸茶缃殑鍊间负:[{{this.loneTreeNewForm.btmTypeName}}]</div> - <div style="padding-top: 10px;display: flex; justify-content: flex-end;float: right;overflow: hidden" > - <el-button type="primary" size="small" @click="btmHandlerClick">纭畾</el-button> - <el-button size="small" @click="BtmEscHandler">鍙栨秷</el-button> - </div> - </div> - </el-dialog> + <ThemeChildren + ref="ThemeBtmChildren" + :SelectOption="btmSelectOption" + :TreeAddform="loneTreeNewForm" + :visible.sync="BtmdialogVisible" + codeName="btmTypeName" + codeType="btmCode" + dialogTitle="涓氬姟绫诲瀷" + @defineHandler="handlerDefine" + ></ThemeChildren> </div> </div> </template> @@ -128,28 +59,16 @@ <script> import {defaultReferDataGrid,referDataGrid} from '@/api/MasterData/master' import {TreeEditSave} from '@/api/template/templateAttr' +import ThemeChildren from '@/components/FormTemplate/ThemeChildren' export default { + components: {ThemeChildren}, name: "classifyTreeform.vue", props: ['loneTreeNewForm','flag','Editclose','TreeFlag','nodeClickList'], data() { return { masterRow:null, - SelectFInd:"", - masterName:"", - masterOid:"", - KeyName:"", - KeyOid:"", - simName:"", - simOid:"", - btmName:"", - btmOid:"", - btmId:"", masterInput:'', MasterSearchSelects:"", - masterData:[], - KeyData:[], - simData:[], - BtmData:[], SelectOption:[ { value: 'name', @@ -160,7 +79,7 @@ label: '鑻辨枃鍚嶇О' } ], - masterSelectOption:[ + btmSelectOption:[ { value: 'id', label: '涓氬姟绫诲瀷缂栧彿' @@ -170,89 +89,6 @@ label: '涓氬姟绫诲瀷鍚嶇О' }, ], - SelectValue:'id', - btmOption:{ - columnBtn: false, - refreshBtn:false, - addBtn:false, - index:true, - border:true, - selection:true, - menu:false, - height:380, - column:[ - { - label:'涓氬姟绫诲瀷缂栧彿', - prop:'id' - }, - { - label:'涓氬姟绫诲瀷鍚嶇О', - prop:'name' - }, - { - label:'鎻忚堪', - prop:'description' - } - ] - }, - attrOption:{ - addBtn:false, - columnBtn: false, - refreshBtn:false, - index:true, - border:true, - menu:false, - height:380, - column:[ - { - label: '', - prop: 'radio', - width: 60, - display: false - }, - { - label:'鑻辨枃缂栧彿', - prop:'id' - }, - { - label:'涓枃鍚嶇О', - prop:'name' - }, - { - label:'鎻忚堪', - prop:'description' - } - ] - }, - masterOption:{ - columnBtn: false, - refreshBtn:false, - addBtn:false, - index:true, - border:true, - menu:false, - height:380, - column:[ - { - label: '', - prop: 'radio', - width: 60, - display: false - }, - { - label:'涓氬姟绫诲瀷缂栧彿', - prop:'id' - }, - { - label:'涓氬姟绫诲瀷鍚嶇О', - prop:'name' - }, - { - label:'鎻忚堪', - prop:'description' - } - ] - }, MasterdialogVisible:false, KeydialogVisible:false, SimidialogVisible:false, @@ -261,7 +97,7 @@ name: "鍝堝搱", sex: "鐢�" }, - option: { + renonlyOption: { submitBtn:false, emptyBtn:false, columnBtn:false, @@ -351,7 +187,7 @@ } }, computed:{ - options(){ + editOption(){ return{ column: [ { @@ -396,7 +232,7 @@ label:"缂栫爜瑙勫垯", prop:"codeRuleOidName", labelWidth:128, - focus:this.CodeFoucus, + focus:this.CodeFocus, readonly: true, }, { @@ -444,6 +280,34 @@ created() { }, methods: { + //鏍戠紪杈戝弬鐓у瓙缁勪欢浜嬩欢 + handlerDefine(val) { + const codeTypeMap = { + coderule: { + nameKey: 'codeRuleOidName', + oidKey: 'codeRuleOid' + }, + codekeyattrrepeat: { + nameKey: 'codeKeyAttrRepeatOidName', + oidKey: 'codeKeyAttrRepeatOid' + }, + coderesemblerule: { + nameKey: 'codeResembleRuleOidName', + oidKey: 'codeResembleRuleOid' + }, + btmCode: { + nameKey: 'btmTypeName', + oidKey: 'btmTypeId' + } + }; + + const codeType = codeTypeMap[val.codeType]; + if (codeType) { + this.$set(this.loneTreeNewForm, codeType.nameKey, val.crudName); + this.$set(this.loneTreeNewForm, codeType.oidKey, val.crudOid); + this.$emit('MasterHandler', this.loneTreeNewForm); + } + }, submits(form,done){ if(this.TreeFlag){ TreeEditSave(this.loneTreeNewForm).then(res=>{ @@ -468,204 +332,27 @@ error(err) { this.$message.success(err); }, - //缂栫爜瑙勫垯鍏抽棴 - masterEscHandler(){ - this.SelectFInd=''; - this.SelectValue='id'; - this.masterRow=null; - this.MasterdialogVisible=false; - }, - //鍏抽敭灞炴�у叧闂� - KeyEscHandler(){ - this.SelectFInd=''; - this.SelectValue='id'; - this.masterRow=null; - this.KeydialogVisible=false; - }, - //鐩镐技椤瑰叧闂� - simEscHandler(){ - this.SelectFInd=''; - this.SelectValue='id'; - this.masterRow=null; - this.SimidialogVisible=false; - }, - //瀛樺偍涓氬姟绫诲瀷鍏抽棴 - BtmEscHandler(){ - this.SelectFInd=''; - this.SelectValue='id'; - this.masterRow=null; - this.BtmdialogVisible=false; - }, - //缂栫爜瑙勫垯鏌ヨ - SelectFindeHandler(){ - const masterParameter = {}; - masterParameter[`conditionMap['${this.SelectValue}']`] = this.SelectFInd; - this.MasterdefaultRend(masterParameter) - }, //缂栫爜瑙勫垯澶辩劍 - CodeFoucus(){ + CodeFocus(){ this.MasterdialogVisible=true; - this.MasterdefaultRend() - }, - //缂栫爜瑙勫垯纭畾 - MasterHandlerClick(){ - if(this.masterSelectList.length>1){ - this.$message.warning('鍙兘閫夋嫨涓�鏉℃暟鎹�') - }else if(this.masterSelectList.length<=0){ - this.$message.warning('璇烽�夋嫨涓�鏉℃暟鎹�') - }else { - this.MasterdialogVisible=false; - this.masterSelectList=[] - this.$set(this.loneTreeNewForm,'codeRuleOidName',this.masterName) - this.$set(this.loneTreeNewForm,'codeRuleOid',this.masterOid) - this.$emit('MasterHandler',this.loneTreeNewForm) - } - }, - //缂栫爜澶氶�� - masterSelect(row){ - this.masterRow = row.$index; - this.masterSelectList = row; - this.masterName = row.name; - this.masterOid = row.oid; - }, - //缂栫爜鎺ュ彛 - MasterdefaultRend(masterParameter){ - defaultReferDataGrid({ - referType:'coderule', - isMuti:'false', - 'conditionMap["lcstatus"]':'Released', - 'limit':'-1', - ...masterParameter - }).then(res=>{ - this.masterData=res.data.records; - }) + this.$refs.ThemeMasterChildren.defaultSearchRend() }, //鍏抽敭灞炴�уけ鐒� Keyfouce(){ this.KeydialogVisible=true; - this.KeydefaultRend() - }, - //鍏抽敭灞炴�х‘瀹� - KeyHandlerClick(){ - if(this.KeySelectLIst.length>1){ - this.$message.warning('鍙兘閫夋嫨涓�鏉℃暟鎹�') - }else if(this.KeySelectLIst.length<=0){ - this.$message.warning('璇烽�夋嫨涓�鏉℃暟鎹�') - }else { - this.KeydialogVisible=false; - this.KeySelectLIst=[] - this.$set(this.loneTreeNewForm,'codeKeyAttrRepeatOidName',this.KeyName) - this.$set(this.loneTreeNewForm,'codeKeyAttrRepeatOid',this.KeyOid) - this.$emit('MasterHandler',this.loneTreeNewForm) - } - }, - //鍏抽敭灞炴�ф煡璇� - KeySelectFindeHandler(){ - const masterParameter = {}; - masterParameter[`conditionMap['${this.SelectValue}']`] = this.SelectFInd; - this.KeydefaultRend(masterParameter) - }, - //鍏抽敭灞炴�ф帴鍙� - KeydefaultRend(masterParameter){ - defaultReferDataGrid({ - referType:'codekeyattrrepeat', - isMuti:'false', - 'conditionMap["lcstatus"]':'Enabled', - 'limit':'-1', - ...masterParameter - }).then(res=>{ - this.KeyData=res.data.records; - }) - }, - //鍏抽敭澶氶�� - KeySelect(row){ - this.masterRow = row.$index; - this.KeySelectLIst = row; - this.KeyName = row.name; - this.KeyOid = row.oid; + this.$refs.ThemeKeyChildren.defaultSearchRend(); }, //鐩镐技椤瑰け鐒� simFouce(){ this.SimidialogVisible=true; - this.simdefaultRend() + this.$refs.ThemeSimChildren.defaultSearchRend(); }, - //鐩镐技椤圭‘瀹� - simHandlerClick(){ - if(this.simSelectList.length>1){ - this.$message.warning('鍙兘閫夋嫨涓�鏉℃暟鎹�') - }else if(this.simSelectList.length<=0){ - this.$message.warning('璇烽�夋嫨涓�鏉℃暟鎹�') - }else { - this.SimidialogVisible=false; - this.simSelectList=[] - this.$set(this.loneTreeNewForm,'codeResembleRuleOidName',this.simName) - this.$set(this.loneTreeNewForm,'codeResembleRuleOid',this.simOid) - this.$emit('MasterHandler',this.loneTreeNewForm) - } - }, - //鐩镐技椤规煡璇� - SimSelectFindeHandler(){ - const masterParameter = {}; - masterParameter[`conditionMap['${this.SelectValue}']`] = this.SelectFInd; - this.simdefaultRend(masterParameter) - }, - //鐩镐技椤瑰閫� - simSelect(row){ - this.masterRow = row.$index; - this.simSelectList = row; - this.simName = row.name; - this.simOid = row.oid; - }, - //鐩镐技椤归」鎺ュ彛 - simdefaultRend(masterParameter){ - defaultReferDataGrid({ - referType:'coderesemblerule', - isMuti:'false', - 'conditionMap["lcstatus"]':'Enabled', - 'limit':'-1', - ...masterParameter - }).then(res=>{ - this.simData=res.data.records; - }) - }, + //涓氬姟绫诲瀷澶辩劍 btmFoucus(){ - this.BtmdialogVisible=true; - this.btmdefaultRend() + this.BtmdialogVisible = true; + this.$refs.ThemeBtmChildren.btmDefaultRend(); }, - //涓氬姟绫诲瀷纭畾 - btmHandlerClick(){ - if(this.btmSelectList.length>1){ - this.$message.warning('鍙兘閫夋嫨涓�鏉℃暟鎹�') - }else if(this.btmSelectList.length<=0){ - this.$message.warning('璇烽�夋嫨涓�鏉℃暟鎹�') - }else { - this.BtmdialogVisible=false; - this.btmSelectList=[] - this.$set(this.loneTreeNewForm,'btmTypeName',this.btmName ||this.btmId) - this.$set(this.loneTreeNewForm,'btmTypeId',this.btmId) - this.$emit('MasterHandler',this.loneTreeNewForm) - } - }, - //涓氬姟绫诲瀷鏌ヨ - BtmSelectFindeHandler(){ - const masterParameter = {}; - masterParameter[`conditionMap['${this.SelectValue}']`] = this.SelectFInd; - this.btmdefaultRend(masterParameter); - }, - //涓氬姟绫诲瀷澶氶�� - btmSelect(row){ - this.btmSelectList=row; - this.btmName=row.name; - this.btmOid=row.oid; - this.btmId=row.id; - }, - //涓氬姟绫诲瀷鎺ュ彛 - btmdefaultRend(masterParameter){ - referDataGrid({valueField:'id',isMuti:'false','limit':'-1',...masterParameter}).then(res=>{ - this.BtmData=res.data.data.records - }) - } } } </script> diff --git a/Source/UBCS-WEB/src/components/Theme/ThemeClassifyTrees.vue b/Source/UBCS-WEB/src/components/Theme/ThemeClassifyTrees.vue index c8f38c1..6184ec2 100644 --- a/Source/UBCS-WEB/src/components/Theme/ThemeClassifyTrees.vue +++ b/Source/UBCS-WEB/src/components/Theme/ThemeClassifyTrees.vue @@ -4,18 +4,34 @@ <!-- 宸︿晶鑿滃崟--> <el-aside> <basic-container> - <div style="height: calc(100vh - 142px);!important;"> + <div style="height: calc(100vh - 142px);!important;"> <div class="headerCon" style="display: flex; flex-wrap: wrap;margin-bottom: 5px"> - <el-button v-if="permissionList.TreeAddStatus" plain size="small" type="primary" @click="TreeAdd">娣诲姞</el-button> - <el-button v-if="permissionList.TreeEditStatus" plain size="small" type="primary" @click="TreeEdit">淇敼</el-button> - <el-button v-if="permissionList.TreeDelStatus" plain size="small" type="primary" @click="TreeDel">鍒犻櫎</el-button> - <el-button v-if="permissionList.flushedStatus" plain size="small" type="primary" @click="flushed">鍒锋柊</el-button> - <el-button v-if="permissionList.EnableStatus" plain size="small" type="primary" @click="Enable">鍚敤</el-button> - <el-button v-if="permissionList.DeactivateStatus" plain size="small" type="primary" @click="Deactivate">鍋滅敤</el-button> - <el-button v-if="permissionList.ImportExcelStatus" plain size="small" type="primary" @click.native="ImportExcel">瀵煎叆</el-button> - <el-button v-if="permissionList.ExportExcelStatus" plain size="small" type="primary" @click="ExportExcel">瀵煎嚭</el-button> - <el-button style="width: 56px;text-align: center;padding-left: 3px" v-if="permissionList.flowingBtnStuatus" plain size="small" type="primary" @click="flowingDependHandler">娴佹按澶勭悊</el-button> - <el-button style="width: 56px;text-align: center;padding-left: 3px" v-if="permissionList.classifyAuth" plain size="small" type="primary" @click="classifyAuthHandler">鍒嗙被鎺堟潈</el-button> + <el-button v-if="permissionList.TreeAddStatus" plain size="small" type="primary" @click="TreeAdd">娣诲姞 + </el-button> + <el-button v-if="permissionList.TreeEditStatus" plain size="small" type="primary" @click="TreeEdit">淇敼 + </el-button> + <el-button v-if="permissionList.TreeDelStatus" plain size="small" type="primary" @click="TreeDel">鍒犻櫎 + </el-button> + <el-button v-if="permissionList.flushedStatus" plain size="small" type="primary" @click="flushed">鍒锋柊 + </el-button> + <el-button v-if="permissionList.EnableStatus" plain size="small" type="primary" @click="Enable">鍚敤 + </el-button> + <el-button v-if="permissionList.DeactivateStatus" plain size="small" type="primary" @click="Deactivate">鍋滅敤 + </el-button> + <el-button v-if="permissionList.ImportExcelStatus" plain size="small" type="primary" + @click.native="ImportExcel">瀵煎叆 + </el-button> + <el-button v-if="permissionList.ExportExcelStatus" plain size="small" type="primary" @click="ExportExcel"> + 瀵煎嚭 + </el-button> + <el-button v-if="permissionList.flowingBtnStuatus" plain + size="small" style="width: 56px;text-align: center;padding-left: 3px" type="primary" + @click="flowingDependHandler">娴佹按澶勭悊 + </el-button> + <el-button v-if="permissionList.classifyAuth" plain size="small" + style="width: 56px;text-align: center;padding-left: 3px" type="primary" + @click="classifyAuthHandler">鍒嗙被鎺堟潈 + </el-button> </div> <!-- 宸︿晶鏍�--> @@ -253,147 +269,58 @@ </template> </avue-crud> </basic-container> - <templatePro :Formlist="this.Formlist" :ProData="this.ProData" :codeClassifyOid="this.codeClassifyOid" - :crudArray="this.crudArray" :crudLCStatus="this.crudLCStatus" :crudOid="this.crudOid" - :rowIndex="this.selectRow" :btnAuthList="btnAuthList"></templatePro> + <templatePro :Formlist="this.Formlist" :ProData="this.ProData" :btnAuthList="btnAuthList" + :codeClassifyOid="this.codeClassifyOid" :crudArray="this.crudArray" + :crudLCStatus="this.crudLCStatus" + :crudOid="this.crudOid" :rowIndex="this.selectRow"></templatePro> </span> <!-- 缂栫爜瑙勫垯--> - <el-dialog :before-close="masterEscHandler" :visible.sync="MasterdialogVisible" append-to-body - title="涓恒�愮紪鐮佽鍒欍�戦�夊彇鍊�"> - <template> - <el-select v-model="SelectValue" placeholder="璇烽�夋嫨" style="width: 135px"> - <el-option - v-for="item in SelectOption" - :key="item.value" - :label="item.label" - :value="item.value" - style="width: 150px"> - </el-option> - </el-select> - <el-input v-model="SelectFInd" placeholder="杈撳叆鍊煎悗杩涜妯$硦鏌ヨ" style="width: 260px;margin-left: 15px"></el-input> - <el-button plain size="small" style="margin-left: 20px" type="primary" @click="SelectFindeHandler">鏌ヨ - </el-button> - </template> - <avue-crud :data="masterData" :option="Option" @row-click="masterSelect"> - <template slot="radio" slot-scope="{row}"> - <el-radio v-model="masterRow" :label="row.$index" style="padding-left: 10px !important;">{{ '' }} - </el-radio> - </template> - </avue-crud> - <div style="height: 30px"> - <div - style="display: inline-block;float: left;border: 1px solid #eeeeee;padding: 5px;margin-top: 5px;font-size: 14px "> - 宸茶缃殑鍊间负:[{{ this.TreeAddform.coderuleoidName == '' ? '鏈缃��' : this.TreeAddform.coderuleoidName }}] - </div> - <div style="padding-top: 10px;display: flex; justify-content: flex-end;float: right;overflow: hidden"> - <el-button size="small" type="primary" @click="MasterHandlerClick">纭畾</el-button> - <el-button size="small" @click="masterEscHandler">鍙栨秷</el-button> - </div> - </div> - </el-dialog> + <ThemeChildren + ref="ThemeMasterChildren" + :SelectOption="SelectOption" + :TreeAddform="TreeAddform" + :visible.sync="MasterdialogVisible" + code-lcstatus="Released" + codeName="codeRuleOidName" + codeType="coderule" + dialogTitle="缂栫爜瑙勫垯" + @defineHandler="handlerDefine" + ></ThemeChildren> <!-- 鍏抽敭灞炴�ф煡璇㈣鍒�--> - <el-dialog :before-close="KeyEscHandler" :visible.sync="KeydialogVisible" append-to-body title="涓恒�愬叧閿睘鎬ф煡璇㈣鍒欍�戦�夊彇鍊�"> - <template> - <el-select v-model="SelectValue" placeholder="璇烽�夋嫨" style="width: 135px"> - <el-option - v-for="item in SelectOption" - :key="item.value" - :label="item.label" - :value="item.value" - style="width: 150px"> - </el-option> - </el-select> - <el-input v-model="SelectFInd" placeholder="杈撳叆鍊煎悗杩涜妯$硦鏌ヨ" style="width: 260px;margin-left: 15px"></el-input> - <el-button plain size="small" style="margin-left: 20px" type="primary" @click="KeySelectFindeHandler">鏌ヨ - </el-button> - </template> - <avue-crud :data="KeyData" :option="Option" @row-click="KeySelect"> - <template slot="radio" slot-scope="{row}"> - <el-radio v-model="masterRow" :label="row.$index" style="padding-left: 10px !important;">{{ '' }} - </el-radio> - </template> - </avue-crud> - <div style="height: 30px"> - <div - style="display: inline-block;float: left;border: 1px solid #eeeeee;padding: 5px;margin-top: 5px;font-size: 14px "> - 宸茶缃殑鍊间负:[{{ - this.TreeAddform.codeKeyAttrRepeatOidName == '' ? '鏈缃��' : this.TreeAddform.codekeyattrrepeatoidName - }}] - </div> - <div style="padding-top: 10px;display: flex; justify-content: flex-end;float: right;overflow: hidden"> - <el-button size="small" type="primary" @click="KeyHandlerClick">纭畾</el-button> - <el-button size="small" @click="KeyEscHandler">鍙栨秷</el-button> - </div> - </div> - </el-dialog> - <!-- 鐩镐技椤规煡璇㈣鍒�--> - <el-dialog :before-close="simEscHandler" :visible.sync="SimidialogVisible" append-to-body title="涓恒�愮浉浼奸」鏌ヨ瑙勫垯銆戦�夊彇鍊�"> - <template> - <el-select v-model="SelectValue" placeholder="璇烽�夋嫨" style="width: 135px"> - <el-option - v-for="item in SelectOption" - :key="item.value" - :label="item.label" - :value="item.value" - style="width: 150px"> - </el-option> - </el-select> - <el-input v-model="SelectFInd" placeholder="杈撳叆鍊煎悗杩涜妯$硦鏌ヨ" style="width: 260px;margin-left: 15px"></el-input> - <el-button plain size="small" style="margin-left: 20px" type="primary" @click="SimSelectFindeHandler">鏌ヨ - </el-button> - </template> - <avue-crud :data="simData" :option="Option" @row-click="simSelect"> - <template slot="radio" slot-scope="{row}"> - <el-radio v-model="masterRow" :label="row.$index" style="padding-left: 10px !important;">{{ '' }} - </el-radio> - </template> - </avue-crud> - <div style="height: 30px"> - <div - style="display: inline-block;float: left;border: 1px solid #eee;padding: 5px;margin-top: 5px;font-size: 14px "> - 宸茶缃殑鍊间负:[{{ - this.TreeAddform.codeResembleRuleOidName == '' ? '鏈缃��' : this.TreeAddform.codeResembleRuleOidName - }}] - </div> - <div style="padding-top: 10px;display: flex; justify-content: flex-end;float: right;overflow: hidden"> - <el-button size="small" type="primary" @click="simHandlerClick">纭畾</el-button> - <el-button size="small" @click="simEscHandler">鍙栨秷</el-button> - </div> - </div> - </el-dialog> - <!-- 涓氬姟绫诲瀷--> - <el-dialog :before-close="BtmEscHandler" :visible.sync="BtmdialogVisible" append-to-body title="涓恒�愪笟鍔$被鍨嬭鍒欍�戦�夊彇鍊�"> - <template> - <el-select v-model="SelectValue" placeholder="璇烽�夋嫨" style="width: 135px !important;"> - <el-option - v-for="item in masterSelectOption" - :key="item.value" - :label="item.label" - :value="item.value" - style="width: 130px"> - </el-option> - </el-select> - <el-input v-model="SelectFInd" placeholder="杈撳叆鍊煎悗杩涜妯$硦鏌ヨ" style="width: 260px;margin-left: 15px"></el-input> - <el-button plain size="small" style="margin-left: 20px" type="primary" @click="BtmSelectFindeHandler">鏌ヨ - </el-button> - </template> - <avue-crud :data="BtmData" :option="masterOption" @row-click="btmSelect"> - <template slot="radio" slot-scope="{row}"> - <el-radio v-model="masterRow" :label="row.$index" style="padding-left: 10px !important;">{{ '' }} - </el-radio> - </template> - </avue-crud> - <div style="height: 30px"> - <div - style="display: inline-block;float: left;border: 1px solid #eee;padding: 5px;margin-top: 5px;font-size: 14px "> - 宸茶缃殑鍊间负:[{{ this.TreeAddform.btmTypeName }}] - </div> - <div style="padding-top: 10px;display: flex; justify-content: flex-end;float: right;overflow: hidden"> - <el-button size="small" type="primary" @click="btmHandlerClick">纭畾</el-button> - <el-button size="small" @click="BtmEscHandler">鍙栨秷</el-button> - </div> - </div> - </el-dialog> + <ThemeChildren + ref="ThemeKeyChildren" + :SelectOption="SelectOption" + :TreeAddform="TreeAddform" + :visible.sync="KeydialogVisible" + code-lcstatus="Enabled" + codeName="codeKeyAttrRepeatOidName" + codeType="codekeyattrrepeat" + dialogTitle="鍏抽敭灞炴�ф煡璇㈣鍒�" + @defineHandler="handlerDefine" + ></ThemeChildren> + <!-- 鐩镐技椤规煡璇㈣鍒� --> + <ThemeChildren + ref="ThemeSimChildren" + :SelectOption="SelectOption" + :TreeAddform="TreeAddform" + :visible.sync="SimidialogVisible" + code-lcstatus="Enabled" + codeName="codeResembleRuleOidName" + codeType="coderesemblerule" + dialogTitle="鐩镐技椤规煡璇㈣鍒�" + @defineHandler="handlerDefine" + ></ThemeChildren> + <!-- 涓氬姟绫诲瀷 --> + <ThemeChildren + ref="ThemeBtmChildren" + :SelectOption="btmSelectOption" + :TreeAddform="TreeAddform" + :visible.sync="BtmdialogVisible" + codeName="btmTypeName" + codeType="btmCode" + dialogTitle="涓氬姟绫诲瀷" + @defineHandler="handlerDefine" + ></ThemeChildren> <!-- 瀵煎嚭--> <ThemeImport :codeClassifyOid="this.codeClassifyOid" :visible.sync="ThemeImportVisible"></ThemeImport> </basic-container> @@ -428,9 +355,10 @@ import {mapGetters} from "vuex"; import ClassifyAuth from './ClassifyAuthDialog.vue'; import {getAuthButtonList} from '@/api/system/classifyAuth' +import ThemeChildren from '@/components/FormTemplate/ThemeChildren' export default { - components: {ClassifyAuth}, + components: {ClassifyAuth, ThemeChildren}, name: "classifyTrees.vue", data() { return { @@ -450,86 +378,12 @@ editTreeFLagCode: false, //缂栫爜瑙勫垯 MasterdialogVisible: false, - masterData: [], - masterSelectList: [], - masterName: "", - masterOid: "", - //鍏抽敭灞炴�tmTypeId + //鍏抽敭灞炴�� KeydialogVisible: false, - KeyName: "", - KeyOid: "", - KeyData: [], - KeySelectLIst: [], //鐩镐技椤� - simName: "", - simOid: "", - simData: [], SimidialogVisible: false, - simSelectList: [], //涓氬姟绫诲瀷 - btmName: "", - btmOid: "", - BtmData: [], BtmdialogVisible: false, - btmSelectList: [], - masterOption: { - addBtn: false, - index: true, - refreshBtn: false, - columnBtn: false, - border: true, - menu: false, - height: 380, - column: [ - { - label: '', - prop: 'radio', - width: 60, - display: false - }, - { - label: '涓氬姟绫诲瀷缂栧彿', - prop: 'id' - }, - { - label: '涓氬姟绫诲瀷鍚嶇О', - prop: 'name' - }, - { - label: '鎻忚堪', - prop: 'description' - } - ] - }, - Option: { - addBtn: false, - index: true, - columnBtn: false, - refreshBtn: false, - border: true, - menu: false, - height: 380, - column: [ - { - label: '', - prop: 'radio', - width: 60, - display: false - }, - { - label: '鑻辨枃鍚嶇О', - prop: 'id' - }, - { - label: '涓枃鍚嶇О', - prop: 'name' - }, - { - label: '鎻忚堪', - prop: 'description' - } - ] - }, SelectOption: [ { value: 'name', @@ -540,7 +394,7 @@ label: '鑻辨枃鍚嶇О' } ], - masterSelectOption: [ + btmSelectOption: [ { value: 'id', label: '涓氬姟绫诲瀷缂栧彿' @@ -550,8 +404,6 @@ label: '涓氬姟绫诲瀷鍚嶇О' }, ], - SelectValue: "id", - SelectFInd: "", addFlag: false, // 琛ㄦ牸褰撳墠琛宨d crudOid: "", @@ -922,34 +774,6 @@ switchChange() { this.TreeAddform.isParticipateCheck = this.TreeAddform.codeKeyAttrValue === true ? 1 : 0; }, - //瀛樺偍鐨勪笟鍔$被鍨嬪叧闂� - BtmEscHandler() { - this.SelectFInd = ''; - this.SelectValue = 'id'; - this.masterRow = null; - this.BtmdialogVisible = false; - }, - //鐩镐技椤瑰叧闂� - simEscHandler() { - this.SelectFInd = ''; - this.SelectValue = 'id'; - this.masterRow = null; - this.SimidialogVisible = false; - }, - //鍏抽敭灞炴�у叧闂� - KeyEscHandler() { - this.SelectFInd = ''; - this.SelectValue = 'id'; - this.masterRow = null; - this.KeydialogVisible = false; - }, - //缂栫爜瑙勫垯鍏抽棴 - masterEscHandler() { - this.SelectFInd = ''; - this.SelectValue = 'id'; - this.masterRow = null; - this.MasterdialogVisible = false; - }, // 鍏抽棴寮圭獥 /** 瀵煎叆 */ ImportExcel() { @@ -965,179 +789,56 @@ this.$message.warning('璇峰厛閫夋嫨瑕佸鍑虹殑涓婚搴撳垎绫�') } }, + //鏍戞柊澧炲弬鐓у瓙缁勪欢浜嬩欢 + handlerDefine(val) { + const codeTypeMap = { + coderule: { + nameKey: 'codeRuleOidName', + oidKey: 'codeRuleOid' + }, + codekeyattrrepeat: { + nameKey: 'codeKeyAttrRepeatOidName', + oidKey: 'codeKeyAttrRepeatOid' + }, + coderesemblerule: { + nameKey: 'codeResembleRuleOidName', + oidKey: 'codeResembleRuleOid' + }, + btmCode: { + nameKey: 'btmTypeName', + oidKey: 'btmTypeId', + clearValidate: true + } + }; + + const codeType = codeTypeMap[val.codeType]; + if (codeType) { + if (codeType.clearValidate) { + this.$refs.myForm.clearValidate(); + } + this.$set(this.TreeAddform, codeType.nameKey, val.crudName); + this.$set(this.TreeAddform, codeType.oidKey, val.crudOid); + } + }, //缂栫爜瑙勫垯澶辩劍 CodeFoucus() { this.MasterdialogVisible = true; - this.MasterdefaultRend() + this.$refs.ThemeMasterChildren.defaultSearchRend() }, - //缂栫爜澶氶�� - masterSelect(row) { - this.masterRow = row.$index; - this.masterSelectList = row; - this.masterName = row.name; - this.masterOid = row.oid; - - }, - //缂栫爜瑙勫垯鏌ヨ - SelectFindeHandler() { - const masterParameter = {}; - masterParameter[`conditionMap['${this.SelectValue}']`] = this.SelectFInd; - this.MasterdefaultRend(masterParameter) - }, - //缂栫爜瑙勫垯纭畾 - MasterHandlerClick() { - if (this.masterSelectList.length > 1) { - this.$message.warning('鍙兘閫夋嫨涓�鏉℃暟鎹�') - } else if (this.masterSelectList.length <= 0) { - this.$message.warning('璇烽�夋嫨涓�鏉℃暟鎹�') - } else { - this.MasterdialogVisible = false; - this.masterSelectList = [] - this.$set(this.TreeAddform, 'codeRuleOidName', this.masterName) - this.$set(this.TreeAddform, 'codeRuleOid', this.masterOid) - this.$emit('MasterHandler', this.loneTreeNewForm) - this.masterRow = null; - } - }, - //缂栫爜鎺ュ彛 - MasterdefaultRend(masterParameter) { - defaultReferDataGrid({ - referType: 'coderule', - isMuti: 'false', - 'conditionMap["lcstatus"]': 'Released', - 'limit': '-1', - ...masterParameter - }).then(res => { - this.masterData = res.data.records; - }) - }, + //鍏抽敭灞炴�уけ鐒� Keyfouce() { this.KeydialogVisible = true; - this.KeydefaultRend() + this.$refs.ThemeKeyChildren.defaultSearchRend(); }, - //鍏抽敭灞炴�х‘瀹� - KeyHandlerClick() { - if (this.KeySelectLIst.length > 1) { - this.$message.warning('鍙兘閫夋嫨涓�鏉℃暟鎹�') - } else if (this.KeySelectLIst.length <= 0) { - this.$message.warning('璇烽�夋嫨涓�鏉℃暟鎹�') - } else { - this.KeydialogVisible = false; - this.KeySelectLIst = [] - this.$set(this.TreeAddform, 'codeKeyAttrRepeatOidName', this.KeyName) - this.$set(this.TreeAddform, 'codeKeyAttrRepeatOid', this.KeyOid) - this.masterRow = null; - } - }, - //鍏抽敭灞炴�ф煡璇� - KeySelectFindeHandler() { - const masterParameter = {}; - masterParameter[`conditionMap['${this.SelectValue}']`] = this.SelectFInd; - this.KeydefaultRend(masterParameter) - }, - //鍏抽敭灞炴�ф帴鍙� - KeydefaultRend(masterParameter) { - defaultReferDataGrid({ - referType: 'codekeyattrrepeat', - isMuti: 'false', - 'conditionMap["lcstatus"]': 'Enabled', - 'limit': '-1', - ...masterParameter - }).then(res => { - this.KeyData = res.data.records; - }) - }, - // 鍏抽敭澶氶�� - KeySelect(row) { - this.masterRow = row.$index; - this.KeySelectLIst = row; - this.KeyName = row.name; - this.KeyOid = row.oid; - }, - //鍏抽敭澶辩劍 + //鐩镐技椤瑰け鐒� simFouce() { this.SimidialogVisible = true; - this.simdefaultRend() - }, - //鐩镐技椤圭‘瀹� - simHandlerClick() { - if (this.simSelectList.length > 1) { - this.$message.warning('鍙兘閫夋嫨涓�鏉℃暟鎹�') - } else if (this.simSelectList.length <= 0) { - this.$message.warning('璇烽�夋嫨涓�鏉℃暟鎹�') - } else { - this.SimidialogVisible = false; - this.simSelectList = [] - this.$set(this.TreeAddform, 'codeResembleRuleOidName', this.simName) - this.$set(this.TreeAddform, 'codeResembleRuleOid', this.simOid) - this.$emit('MasterHandler', this.loneTreeNewForm) - this.masterRow = null; - } - }, - //鐩镐技椤规煡璇� - SimSelectFindeHandler() { - const masterParameter = {}; - masterParameter[`conditionMap['${this.SelectValue}']`] = this.SelectFInd; - this.simdefaultRend(masterParameter) - }, - // 鐩镐技椤瑰閫� - simSelect(row) { - this.masterRow = row.$index; - this.simSelectList = row; - this.simName = row.name; - this.simOid = row.oid; - }, - //鐩镐技椤归」鎺ュ彛 - simdefaultRend(masterParameter) { - defaultReferDataGrid({ - referType: 'coderesemblerule', - isMuti: 'false', - 'conditionMap["lcstatus"]': 'Enabled', - 'limit': '-1', - ...masterParameter - }).then(res => { - this.simData = res.data.records; - }) + this.$refs.ThemeSimChildren.defaultSearchRend(); }, //涓氬姟绫诲瀷澶辩劍 btmFoucus() { this.BtmdialogVisible = true; - this.btmdefaultRend() - }, - //涓氬姟绫诲瀷纭畾 - btmHandlerClick() { - if (this.btmSelectList.length > 1) { - this.$message.warning('鍙兘閫夋嫨涓�鏉℃暟鎹�') - } else if (this.btmSelectList.length <= 0) { - this.$message.warning('璇烽�夋嫨涓�鏉℃暟鎹�') - } else { - this.$refs.myForm.clearValidate(); - this.BtmdialogVisible = false; - this.btmSelectList = [] - this.$set(this.TreeAddform, 'btmTypeName', this.btmName) - this.$set(this.TreeAddform, 'btmTypeId', this.btmOid) - this.$emit('MasterHandler', this.loneTreeNewForm) - this.masterRow = null; - } - }, - //涓氬姟绫诲瀷鏌ヨ - BtmSelectFindeHandler() { - const masterParameter = {}; - masterParameter[`conditionMap['${this.SelectValue}']`] = this.SelectFInd; - this.btmdefaultRend(masterParameter); - }, - //涓氬姟绫诲瀷澶氶�� - btmSelect(row) { - this.masterRow = row.$index; - this.btmSelectList = row; - this.btmName = row.name; - this.btmOid = row.id; - }, - //涓氬姟绫诲瀷鎺ュ彛 - btmdefaultRend(masterParameter) { - referDataGrid({valueField: 'id', isMuti: 'false', 'limit': '-1', ...masterParameter}).then(res => { - this.BtmData = res.data.data.records - }) + this.$refs.ThemeBtmChildren.btmDefaultRend(); }, //瀛愪紶鐖� MasterHandler(val) { @@ -1763,17 +1464,20 @@ width: 500px; } -.headerCon{ - .el-button+.el-button { +.headerCon { + .el-button + .el-button { margin-left: 5px; } + .el-button { margin-top: 5px; } } + .headerCon > .el-button:nth-child(5) { margin-left: 0; } + .headerCon > .el-button:nth-child(9) { margin-left: 0; } diff --git a/Source/UBCS-WEB/src/views/docking/info.vue b/Source/UBCS-WEB/src/views/docking/info.vue index 1c28481..3fa22d8 100644 --- a/Source/UBCS-WEB/src/views/docking/info.vue +++ b/Source/UBCS-WEB/src/views/docking/info.vue @@ -118,12 +118,13 @@ border: true, index: true, selection: true, + indexFixed: false, + selectionFixed:false, searchShow: false, searchMenuSpan: 6, rowKey: "id", tabs: true, stripe: true, - indexFixed: false, menuWidth: 180, highlightCurrentRow: true, addBtn: false, diff --git a/Source/UBCS-WEB/src/views/docking/loge.vue b/Source/UBCS-WEB/src/views/docking/loge.vue index bb5f6d3..c20a3f9 100644 --- a/Source/UBCS-WEB/src/views/docking/loge.vue +++ b/Source/UBCS-WEB/src/views/docking/loge.vue @@ -126,11 +126,12 @@ data:[], option: { height:'auto', - calcHeight: 0, + calcHeight: 20, tip: false, searchShow: false, border: true, index: true, + indexFixed:false, selection: false, dialogClickModal: false, menuFixed:false, diff --git a/Source/UBCS-WEB/src/views/integration/applicationForm.vue b/Source/UBCS-WEB/src/views/integration/applicationForm.vue index b0e38b4..11602df 100644 --- a/Source/UBCS-WEB/src/views/integration/applicationForm.vue +++ b/Source/UBCS-WEB/src/views/integration/applicationForm.vue @@ -1,216 +1,223 @@ <template> - <basic-container> - <avue-crud :table-loading="loading" :data="data" :option="option" :search.sync="searchParam" :page.sync="page" :permission="permissionList" - ref="crud" @refresh-change="getDataList" @search-change="handleSearch" @search-reset="handleReset" - @size-change="handleSizePage" @current-change="handleCurrentPage" @on-load="getDataList" - @selection-change="selectionChange" @row-click="handleRowClick"> - <template slot="menuLeft"> - <el-button icon="el-icon-document" size="small" type="primary" @click="handleStatus" v-if="permissionList.status">闆嗗洟鐢宠鐘舵�� - </el-button> - </template> - </avue-crud> - </basic-container> + <basic-container> + <avue-crud ref="crud" :data="data" :option="option" :page.sync="page" :permission="permissionList" + :search.sync="searchParam" + :table-loading="loading" @refresh-change="getDataList" @search-change="handleSearch" + @search-reset="handleReset" + @size-change="handleSizePage" @current-change="handleCurrentPage" @on-load="getDataList" + @selection-change="selectionChange" @row-click="handleRowClick"> + <template slot="menuLeft"> + <el-button v-if="permissionList.status" icon="el-icon-document" size="small" type="primary" + @click="handleStatus">闆嗗洟鐢宠鐘舵�� + </el-button> + </template> + </avue-crud> + </basic-container> </template> <script> -import { getList, queryApplyStat } from '@/api/integration/application.js' -import { dateFormat } from '@/util/date.js' +import {getList, queryApplyStat} from '@/api/integration/application.js' +import {dateFormat} from '@/util/date.js' import {mapGetters} from 'vuex' + export default { - data() { - return { - loading: false, - data: [], - page: { - pageSize: 10, - currentPage: 1, - total: 0 - }, - searchParam: {}, - stateParam: {}, - } - }, - computed:{ - ...mapGetters(["permission"]), - permissionList(){ - return{ - searchBtn:this.vaildData(this.permission.applicationForm.applicationForm_search,false), - emptyBtn:this.vaildData(this.permission.applicationForm.applicationForm_search,false), - status:this.vaildData(this.permission.applicationForm.applicationForm_status,false) - } + data() { + return { + loading: false, + data: [], + page: { + pageSize: 10, + currentPage: 1, + total: 0 }, - option(){ - return{ - height: "auto", - tip:false, - index: true, - border: true, - addBtn: false, - columnBtn: false, - searchBtn:this.permissionList.searchBtn, - emptyBtn:this.permissionList.emptyBtn, - searchMenuSpan: 8, - highlightCurrentRow: true, - menu: false, - selection: true, - column: [ - { - label: '鐢宠鍗曞彿', - prop: 'id', - width: 200, - fixed: true, - search: true, - }, { - label: '闆嗗洟鐮�', - width: 150, - prop: 'groupCode', - search: true, - }, { - label: '鎿嶄綔绫诲瀷', - width: 120, - prop: 'operationType', - type: 'select', - search: true, - dicData: [{ - label: '鐢宠', - value: '1' - }, { - label: '鏇存敼', - value: '2' - }] - }, { - label: '鐢宠鍗曟暟鎹俊鎭�', - width: 300, - prop: 'description' - }, - { - label: '鍒涘缓鏃堕棿', - prop: 'createTime', - type: 'datetime', - search: true, - }, - { - label: '鏇存敼鏃堕棿', - prop: 'lastModifyTime', - type: 'datetime', - search: true, - }, { - label: '鏄惁鎴愬姛', - width: 120, - prop: 'code', - html: true, - align:'center', - formatter : function (row) { - return row.code == '1' ? '<i class="el-icon-check" style="color: #32cd32;font-size: 20px;font-weight: 800"></i>' : '<i class="el-icon-close" style="color: #ff0000;font-size: 20px;font-weight: 800"></i>' - } - }, - { - label: '杩斿洖淇℃伅', - prop: 'content', - hide: true - }, - { - label: '娑堟伅淇℃伅', - width: 150, - prop: 'msg' - } - ] + searchParam: {}, + stateParam: {}, + } + }, + computed: { + ...mapGetters(["permission"]), + permissionList() { + return { + searchBtn: this.vaildData(this.permission.applicationForm.applicationForm_search, false), + emptyBtn: this.vaildData(this.permission.applicationForm.applicationForm_search, false), + status: this.vaildData(this.permission.applicationForm.applicationForm_status, false) + } + }, + option() { + return { + height: 'auto', + calcHeight: 20, + tip: false, + index: true, + border: true, + addBtn: false, + columnBtn: false, + searchBtn: this.permissionList.searchBtn, + emptyBtn: this.permissionList.emptyBtn, + searchMenuSpan: 8, + highlightCurrentRow: true, + menu: false, + selection: true, + column: [ + { + label: '鐢宠鍗曞彿', + prop: 'id', + width: 200, + fixed: true, + search: true, + }, { + label: '闆嗗洟鐮�', + width: 150, + prop: 'groupCode', + search: true, + }, { + label: '鎿嶄綔绫诲瀷', + width: 120, + prop: 'operationType', + type: 'select', + search: true, + dicData: [{ + label: '鐢宠', + value: '1' + }, { + label: '鏇存敼', + value: '2' + }] + }, { + label: '鐢宠鍗曟暟鎹俊鎭�', + width: 300, + prop: 'description' + }, + { + label: '鍒涘缓鏃堕棿', + prop: 'createTime', + type: 'datetime', + search: true, + }, + { + label: '鏇存敼鏃堕棿', + prop: 'lastModifyTime', + type: 'datetime', + search: true, + }, { + label: '鏄惁鎴愬姛', + width: 120, + prop: 'code', + html: true, + align: 'center', + formatter: function (row) { + return row.code == '1' ? '<i class="el-icon-check" style="color: #32cd32;font-size: 20px;font-weight: 800"></i>' : '<i class="el-icon-close" style="color: #ff0000;font-size: 20px;font-weight: 800"></i>' + } + }, + { + label: '杩斿洖淇℃伅', + prop: 'content', + hide: true + }, + { + label: '娑堟伅淇℃伅', + width: 150, + prop: 'msg' + } + ] + } + } + }, + methods: { + async handleStatus() { + const {oids} = this.stateParam + if (this.$utilFunc.isEmpty(oids)) { + this.$message({ + type: "error", + message: "璇疯嚦灏戦�夋嫨涓�鏉℃暟鎹�!" + }) + } else { + // console.log(this.stateParam) + const response = await queryApplyStat(this.stateParam) + if (response.status === 200) { + // console.log(response) } } }, - methods: { - async handleStatus() { - const { oids } = this.stateParam - if (this.$utilFunc.isEmpty(oids)) { - this.$message({ - type: "error", - message: "璇疯嚦灏戦�夋嫨涓�鏉℃暟鎹�!" - }) - } else { - // console.log(this.stateParam) - const response = await queryApplyStat(this.stateParam) - if (response.status === 200) { - // console.log(response) - } - } - }, - async getDataList() { - this.loading = true - const { pageSize, currentPage, total } = this.page - let param = { size: pageSize, current: currentPage } - // console.log(this.searchParam) - this.searchParam = Object.keys(this.searchParam) - .filter((key) => this.searchParam[key] !== null && this.searchParam[key] !== undefined && this.searchParam[key] !== "") - .reduce((acc, key) => ({ ...acc, [key]: this.searchParam[key] }), {}); - // console.log(this.searchParam) - const response = await getList({ ...param, ...this.searchParam }) - if (response.status === 200) { - this.loading = false - // console.log(response) - const data = response.data.data - this.data = data.records - this.page.total = data.total - } else this.loading = false - }, - handleSizePage(event) { - this.page.pageSize = event - }, - handleCurrentPage(event) { - this.page.currentPage = event - }, - handleReset() { - this.searchParam = {} - this.getDataList() - }, - handleSearch(form, done) { - // console.log(form) - const { id, groupCode, operationType } = form - let dataTime = { id, groupCode, operationType } - if (form.hasOwnProperty('createTime')) { - dataTime = { createTime: dateFormat(form.createTime), ...dataTime } - } - if (form.hasOwnProperty('lastModifyTime')) { - dataTime = { lastModifyTime: dateFormat(form.lastModifyTime), ...dataTime } - } - this.searchParam = dataTime - this.page.currentPage = 1 - this.getDataList() - done() - }, - selectionChange(list) { - // console.log(list) - let newData = list.map(item => { - const { dataOid } = item - return dataOid - }) - this.stateParam = { oids: newData.toString() } - // console.log(newData) - }, - handleRowClick(row) { - this.$refs.crud.toggleRowSelection(row, true) - }, - } + async getDataList() { + this.loading = true + const {pageSize, currentPage, total} = this.page + let param = {size: pageSize, current: currentPage} + // console.log(this.searchParam) + this.searchParam = Object.keys(this.searchParam) + .filter((key) => this.searchParam[key] !== null && this.searchParam[key] !== undefined && this.searchParam[key] !== "") + .reduce((acc, key) => ({...acc, [key]: this.searchParam[key]}), {}); + // console.log(this.searchParam) + const response = await getList({...param, ...this.searchParam}) + if (response.status === 200) { + this.loading = false + // console.log(response) + const data = response.data.data + this.data = data.records + this.page.total = data.total + } else this.loading = false + }, + handleSizePage(event) { + this.page.pageSize = event + }, + handleCurrentPage(event) { + this.page.currentPage = event + }, + handleReset() { + this.searchParam = {} + this.getDataList() + }, + handleSearch(form, done) { + // console.log(form) + const {id, groupCode, operationType} = form + let dataTime = {id, groupCode, operationType} + if (form.hasOwnProperty('createTime')) { + dataTime = {createTime: dateFormat(form.createTime), ...dataTime} + } + if (form.hasOwnProperty('lastModifyTime')) { + dataTime = {lastModifyTime: dateFormat(form.lastModifyTime), ...dataTime} + } + this.searchParam = dataTime + this.page.currentPage = 1 + this.getDataList() + done() + }, + selectionChange(list) { + // console.log(list) + let newData = list.map(item => { + const {dataOid} = item + return dataOid + }) + this.stateParam = {oids: newData.toString()} + // console.log(newData) + }, + handleRowClick(row) { + this.$refs.crud.toggleRowSelection(row, true) + }, + } } </script> <style lang="scss" scoped> -//鍥哄畾鍒楅珮搴� -/deep/ .el-table__fixed { - height: calc(100vh - 345px)!important; -} -// 婊氬姩鏉℃牱寮忎慨鏀� -// 婊氬姩鏉$殑瀹藉害 -/deep/ .el-table__body-wrapper::-webkit-scrollbar { - height: 15px; // 绾靛悜婊氬姩鏉� 蹇呭啓 - background: white; - border: white; - width: 10px; +////鍥哄畾鍒楅珮搴� +///deep/ .el-table__fixed { +// height: calc(100vh - 345px) !important; +//} -} -// 婊氬姩鏉$殑婊戝潡 -/deep/ .el-table__body-wrapper::-webkit-scrollbar-thumb { - background-color: #ececec; - border-radius: 20px; - border: #ececec; -} +//// 婊氬姩鏉℃牱寮忎慨鏀� +//// 婊氬姩鏉$殑瀹藉害 +///deep/ .el-table__body-wrapper::-webkit-scrollbar { +// height: 15px; // 绾靛悜婊氬姩鏉� 蹇呭啓 +// background: white; +// border: white; +// width: 10px; +// +//} +// +//// 婊氬姩鏉$殑婊戝潡 +///deep/ .el-table__body-wrapper::-webkit-scrollbar-thumb { +// background-color: #ececec; +// border-radius: 20px; +// border: #ececec; +//} </style> diff --git a/Source/UBCS-WEB/src/views/integration/systemInfo.vue b/Source/UBCS-WEB/src/views/integration/systemInfo.vue index 743f91b..0b13756 100644 --- a/Source/UBCS-WEB/src/views/integration/systemInfo.vue +++ b/Source/UBCS-WEB/src/views/integration/systemInfo.vue @@ -113,6 +113,7 @@ option() { return { height: "auto", + calcHeight: 20, tip: false, border: true, align: 'center', diff --git a/Source/UBCS-WEB/src/views/ruleBasic/delimiterConfig.vue b/Source/UBCS-WEB/src/views/ruleBasic/delimiterConfig.vue index 3e79f27..fe02374 100644 --- a/Source/UBCS-WEB/src/views/ruleBasic/delimiterConfig.vue +++ b/Source/UBCS-WEB/src/views/ruleBasic/delimiterConfig.vue @@ -19,7 +19,7 @@ :data="tableData" :header-cell-style="{background:'#FAFAFA',color:'#505050'}" border - style="width: 100%;height: calc(100vh - 320px)" + style="width: 100%;height: calc(100vh - 315px)" @cell-click="cellClickHandler"> <el-table-column align="center" diff --git a/Source/UBCS-WEB/src/views/ruleBasic/paddingCharacter.vue b/Source/UBCS-WEB/src/views/ruleBasic/paddingCharacter.vue index a4c9618..2786221 100644 --- a/Source/UBCS-WEB/src/views/ruleBasic/paddingCharacter.vue +++ b/Source/UBCS-WEB/src/views/ruleBasic/paddingCharacter.vue @@ -19,7 +19,7 @@ :data="tableData" :header-cell-style="{background:'#FAFAFA',color:'#505050'}" border - style="width: 100%;height: calc(100vh - 320px)" + style="width: 100%;height: calc(100vh - 315px)" @cell-click="cellClickHandler"> <el-table-column align="center" diff --git a/Source/UBCS-WEB/src/views/ruleBasic/prefixConfig.vue b/Source/UBCS-WEB/src/views/ruleBasic/prefixConfig.vue index edecfe5..7291218 100644 --- a/Source/UBCS-WEB/src/views/ruleBasic/prefixConfig.vue +++ b/Source/UBCS-WEB/src/views/ruleBasic/prefixConfig.vue @@ -19,7 +19,7 @@ :data="tableData" :header-cell-style="{background:'#FAFAFA',color:'#505050'}" border - style="width: 100%;height: calc(100vh - 320px)" + style="width: 100%;height: calc(100vh - 315px)" @cell-click="cellClickHandler"> <el-table-column align="center" diff --git a/Source/UBCS-WEB/src/views/ruleBasic/usableCharacter.vue b/Source/UBCS-WEB/src/views/ruleBasic/usableCharacter.vue index 32997d5..d832be8 100644 --- a/Source/UBCS-WEB/src/views/ruleBasic/usableCharacter.vue +++ b/Source/UBCS-WEB/src/views/ruleBasic/usableCharacter.vue @@ -19,7 +19,7 @@ :data="tableData" :header-cell-style="{background:'#FAFAFA',color:'#505050'}" border - style="width: 100%;height: calc(100vh - 320px)" + style="width: 100%;height: calc(100vh - 315px)" @cell-click="cellClickHandler"> <el-table-column align="center" label="1" prop="1"></el-table-column> <el-table-column align="center" label="2" prop="2"></el-table-column> -- Gitblit v1.9.3