Merge remote-tracking branch 'origin/master'
¶Ô±ÈÐÂÎļþ |
| | |
| | | <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> |
| | |
| | | <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> |
| | |
| | | <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', |
| | |
| | | label: 'è±æåç§°' |
| | | } |
| | | ], |
| | | masterSelectOption:[ |
| | | btmSelectOption:[ |
| | | { |
| | | value: 'id', |
| | | label: 'ä¸å¡ç±»åç¼å·' |
| | |
| | | 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, |
| | |
| | | name: "åå", |
| | | sex: "ç·" |
| | | }, |
| | | option: { |
| | | renonlyOption: { |
| | | submitBtn:false, |
| | | emptyBtn:false, |
| | | columnBtn:false, |
| | |
| | | } |
| | | }, |
| | | computed:{ |
| | | options(){ |
| | | editOption(){ |
| | | return{ |
| | | column: [ |
| | | { |
| | |
| | | label:"ç¼ç è§å", |
| | | prop:"codeRuleOidName", |
| | | labelWidth:128, |
| | | focus:this.CodeFoucus, |
| | | focus:this.CodeFocus, |
| | | readonly: true, |
| | | }, |
| | | { |
| | |
| | | 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=>{ |
| | |
| | | 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> |
| | |
| | | <!-- 左侧èå--> |
| | | <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> |
| | | <!-- 左侧æ --> |
| | | |
| | |
| | | </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> |
| | |
| | | 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 { |
| | |
| | | editTreeFLagCode: false, |
| | | //ç¼ç è§å |
| | | MasterdialogVisible: false, |
| | | masterData: [], |
| | | masterSelectList: [], |
| | | masterName: "", |
| | | masterOid: "", |
| | | //å
³é®å±æ§btmTypeId |
| | | //å
³é®å±æ§ |
| | | 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', |
| | |
| | | label: 'è±æåç§°' |
| | | } |
| | | ], |
| | | masterSelectOption: [ |
| | | btmSelectOption: [ |
| | | { |
| | | value: 'id', |
| | | label: 'ä¸å¡ç±»åç¼å·' |
| | |
| | | label: 'ä¸å¡ç±»ååç§°' |
| | | }, |
| | | ], |
| | | SelectValue: "id", |
| | | SelectFInd: "", |
| | | addFlag: false, |
| | | // è¡¨æ ¼å½åè¡id |
| | | crudOid: "", |
| | |
| | | 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() { |
| | |
| | | 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) { |
| | |
| | | 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; |
| | | } |
| | |
| | | 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, |
| | |
| | | data:[], |
| | | option: { |
| | | height:'auto', |
| | | calcHeight: 0, |
| | | calcHeight: 20, |
| | | tip: false, |
| | | searchShow: false, |
| | | border: true, |
| | | index: true, |
| | | indexFixed:false, |
| | | selection: false, |
| | | dialogClickModal: false, |
| | | menuFixed:false, |
| | |
| | | <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> |
| | |
| | | option() { |
| | | return { |
| | | height: "auto", |
| | | calcHeight: 20, |
| | | tip: false, |
| | | border: true, |
| | | align: 'center', |
| | |
| | | :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" |
| | |
| | | :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" |
| | |
| | | :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" |
| | |
| | | :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> |