| | |
| | | append-to-body |
| | | :visible.sync="crudParams.isShowDialog" |
| | | width="65%" |
| | | top="0" |
| | | class= "avue-dialog avue-dialog--top" |
| | | destroy-on-close |
| | | @close="clearTableRowSelection" |
| | | style="height: 110vh; margin-top: -12vh; overflow-y: hidden"> |
| | |
| | | addBtn: false, |
| | | menu: false, |
| | | // refreshBtn: false, |
| | | disablePage: false, |
| | | searchShowBtn: false, |
| | | columnBtn: false, |
| | | dialogClickModal: false, |
| | |
| | | },{ |
| | | label: '属性长度', |
| | | search: false, |
| | | prop: 'attrLength' |
| | | prop: 'attributeLength' |
| | | },{ |
| | | label: '属性类型', |
| | | search: false, |
| | | prop: 'attrType' |
| | | prop: 'attrDataTypeText' |
| | | }], |
| | | }, |
| | | crudData: [], |
| | |
| | | this.options = params; |
| | | this.crudParams.crudLoading = true; |
| | | // 调用api请求 |
| | | const data = { |
| | | total: 2, |
| | | data: [{ |
| | | id: 'test', |
| | | name: '测试', |
| | | attrLength: 11, |
| | | attrType: '字符串' |
| | | }, { |
| | | id: 'test1', |
| | | name: '测试1', |
| | | attrLength: 12, |
| | | attrType: '数字' |
| | | }] |
| | | } |
| | | // const data = { |
| | | // total: 2, |
| | | // data: [{ |
| | | // id: 'test', |
| | | // name: '测试', |
| | | // attrLength: 11, |
| | | // attrType: '字符串' |
| | | // }, { |
| | | // id: 'test1', |
| | | // name: '测试1', |
| | | // attrLength: 12, |
| | | // attrType: '数字' |
| | | // }] |
| | | // } |
| | | let param = {}; |
| | | // 多个conditionMap这样传参 |
| | | if(this.crudParams.crudQuery){ |
| | | Object.keys(crudParams.crudQuery).forEach(key=>{ |
| | | param['conditionMap['+key+']'] = crudParams.crudQuery[key]; |
| | | Object.keys(this.crudParams.crudQuery).forEach(key=>{ |
| | | param['conditionMap['+key+']'] = this.crudParams.crudQuery[key]; |
| | | }); |
| | | } |
| | | param['conditionMap[btmTypeId]'] = this.options.btmTypeId; |
| | | gridAttributesByBtmId(1,-1,param).then(res=>{ |
| | | console.log(res); |
| | | const data = res.data; |
| | | // console.log(data.data.records); |
| | | this.crudParams.crudData = data.data.records; |
| | | this.crudParams.crudLoading = false; |
| | | this.$nextTick(()=>{ |
| | | this.$refs[this.crudParams.ref].doLayout(); |
| | | }) |
| | | }) |
| | | this.crudParams.crudData = data.data; |
| | | this.crudParams.crudLoading = false; |
| | | |
| | | }, |
| | | selectedBtmTypeAttrSrchChange(params, done){ |
| | | this.crudParams.crudQuery = params; |