|
@@ -20,8 +20,8 @@
|
|
|
<div :class="dataFlag ? 'tableAuto' : treeData.length ? 'tableSacle' : 'tableAuto'" class="TablePage_content_right">
|
|
|
<div class="check_header">
|
|
|
<el-scrollbar style="height: 100%" :horizontal="false">
|
|
|
- <el-form ref="ruleForm" :model="tableForm" :label-width="labelWidth">
|
|
|
- <el-row :gutter="6">
|
|
|
+ <el-form ref="ruleFormw" :model="tableForm" :label-width="labelWidth">
|
|
|
+ <el-row :gutter="2">
|
|
|
<el-col v-for="(item, index) in formItemArr" :key=" index" :span="4" v-show="isShow(item.isdisplay)">
|
|
|
<el-form-item :rules="fromDataReq(item)" :prop="item.pagecode" :label="item.pagename">
|
|
|
<span slot="label">
|
|
@@ -354,18 +354,6 @@ export default {
|
|
|
const pageAuthFforms = pageAuthArrs.filter(item => item.pagetype == 'form')
|
|
|
//获取form表单弹框权限
|
|
|
if (pageAuthFforms?.length) this.getPageBtnFormSetting(pageAuths, pageAuthFforms)
|
|
|
- // this.tableForm = {}
|
|
|
- // for (let k in this.defaultfilter) {
|
|
|
- // if (k != 1) {
|
|
|
- // this.tableForm[k] = this.defaultfilter[k]
|
|
|
- // }
|
|
|
- // }
|
|
|
- // for (let k in this.formItem) {
|
|
|
- // if (this.formItem[k].defaultvalue && this.formItem[k].defaultvalue != "") {
|
|
|
- // this.$set(this.tableForm, this.formItem[k].pagecode, this.formItem[k].defaultvalue)
|
|
|
- // }
|
|
|
- // }
|
|
|
- // this.getSelectData(this.formItem)
|
|
|
},
|
|
|
//根据页面tree设置数据
|
|
|
getPageTreeSetting (pageAuthtrees) {
|
|
@@ -402,7 +390,6 @@ export default {
|
|
|
const formItemCopy = tableColumnArrs.filter((item) => item.isdisplay != 0)
|
|
|
this.formItem = _.orderBy(formItemCopy, ['displaynumber'], ['asc'])
|
|
|
this.getSelectData(this.formItem)
|
|
|
-
|
|
|
},
|
|
|
//获取表头数据
|
|
|
getColumnData (columnArrs = []) {
|
|
@@ -1061,7 +1048,8 @@ export default {
|
|
|
this.noMore = true
|
|
|
}
|
|
|
this.tableData.push(...returnData)
|
|
|
- this.formItemArr = this.tableData
|
|
|
+ this.setPassters(this.tableData)
|
|
|
+ // this.formItemArr = this.tableData
|
|
|
} else {
|
|
|
this.page--
|
|
|
this.noMore = true
|
|
@@ -1076,28 +1064,6 @@ export default {
|
|
|
}
|
|
|
this.loading = false
|
|
|
},
|
|
|
- //获取表单下拉数据
|
|
|
- getSelectData (formItem = []) {
|
|
|
- if (!formItem.length || !Array.isArray(formItem)) return
|
|
|
- const formItemCopy = _.cloneDeep(formItem)
|
|
|
- const [allResult, allResultKey, allResultList] = [[], [], []]
|
|
|
- formItemCopy.map(({ dropdownlist, pagecode, defaultparameters }) => {
|
|
|
- if (((dropdownlist || dropdownlist == 0) && dropdownlist != "")) {
|
|
|
- const datacontent = defaultparameters ? { filter: this.formatDefaults(defaultparameters) } : { filter: { 1: 1 } }
|
|
|
- const params = {
|
|
|
- dropdownlist,
|
|
|
- pagecode,
|
|
|
- datacontent
|
|
|
- }
|
|
|
- allResultList.push(params)
|
|
|
- }
|
|
|
- })
|
|
|
- if (allResultList?.length) {
|
|
|
- this.reduceHttp(allResultList, formItemCopy)
|
|
|
- } else {
|
|
|
- this.formItemArr = formItemCopy
|
|
|
- }
|
|
|
- },
|
|
|
//格式化传递参数数据
|
|
|
formatDefaults (item) {
|
|
|
if (typeof item != 'string') return {}
|
|
@@ -1131,7 +1097,30 @@ export default {
|
|
|
allResultKey.push(pagecode)
|
|
|
allResult.push(Query({ serviceid: dropdownlist, datacontent, event: '0', page: 1, size: 9999 }))
|
|
|
})
|
|
|
+ console.log(columnArrs1)
|
|
|
this.getAnscyData(allResultKey, allResult, _.cloneDeep(formItem), _.cloneDeep(columnArrs1), _.cloneDeep(columnArrs2))
|
|
|
+ },
|
|
|
+ //获取表单下拉数据
|
|
|
+ getSelectData (formItem = []) {
|
|
|
+ if (!formItem.length || !Array.isArray(formItem)) return
|
|
|
+ const formItemCopy = _.cloneDeep(formItem)
|
|
|
+ const [allResult, allResultKey, allResultList] = [[], [], []]
|
|
|
+ formItemCopy.map(({ dropdownlist, pagecode, defaultparameters }) => {
|
|
|
+ if (((dropdownlist || dropdownlist == 0) && dropdownlist != "")) {
|
|
|
+ const datacontent = defaultparameters ? { filter: this.formatDefaults(defaultparameters) } : { filter: { 1: 1 } }
|
|
|
+ const params = {
|
|
|
+ dropdownlist,
|
|
|
+ pagecode,
|
|
|
+ datacontent
|
|
|
+ }
|
|
|
+ allResultList.push(params)
|
|
|
+ }
|
|
|
+ })
|
|
|
+ if (allResultList?.length) {
|
|
|
+ this.reduceHttp(allResultList, formItemCopy)
|
|
|
+ } else {
|
|
|
+ this.formItemArr = formItemCopy
|
|
|
+ }
|
|
|
},
|
|
|
//获取异步数据
|
|
|
async getAnscyData (allResultKey = [], allResult = [], formItem = [], columnArrs1 = [], columnArrs2 = []) {
|