|
@ -273,12 +273,17 @@ const props = defineProps({ |
|
|
required: false, |
|
|
required: false, |
|
|
default: false |
|
|
default: false |
|
|
}, |
|
|
}, |
|
|
// TableForm 的第几列按钮 |
|
|
// TableForm 的第几列按钮 (后续用 fieldTableColumn替换 ,indexTableColumn容易出问题) |
|
|
indexTableColumn :{ |
|
|
indexTableColumn :{ |
|
|
type: Number, |
|
|
type: Number, |
|
|
required: false, |
|
|
required: false, |
|
|
default: 0 |
|
|
default: 0 |
|
|
}, |
|
|
}, |
|
|
|
|
|
fieldTableColumn:{ |
|
|
|
|
|
type: String, |
|
|
|
|
|
required: false, |
|
|
|
|
|
default: '' |
|
|
|
|
|
}, |
|
|
//表单中展示的数据,需要用searchTable中字段计算 |
|
|
//表单中展示的数据,需要用searchTable中字段计算 |
|
|
/***[{ |
|
|
/***[{ |
|
|
formField:form中对应的field, |
|
|
formField:form中对应的field, |
|
@ -385,11 +390,21 @@ const opensearchTable = ( |
|
|
} else { |
|
|
} else { |
|
|
// 扩展 转换为筛选条件进行查询 |
|
|
// 扩展 转换为筛选条件进行查询 |
|
|
if (searchCondition[i].isSearch) { |
|
|
if (searchCondition[i].isSearch) { |
|
|
filters.push({ |
|
|
if (searchCondition[i].isFormModel) { |
|
|
action: searchCondition[i].action, |
|
|
//用formModel中的值 |
|
|
column: searchCondition[i].key, |
|
|
filters.push({ |
|
|
value: searchCondition[i].value |
|
|
action: searchCondition[i].action, |
|
|
}) |
|
|
column: searchCondition[i].key, |
|
|
|
|
|
value: formRef.value.formModel[searchCondition[i].value] |
|
|
|
|
|
}) |
|
|
|
|
|
}else{ |
|
|
|
|
|
filters.push({ |
|
|
|
|
|
action: searchCondition[i].action, |
|
|
|
|
|
column: searchCondition[i].key, |
|
|
|
|
|
value: searchCondition[i].value |
|
|
|
|
|
}) |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
} else { |
|
|
} else { |
|
|
_searchCondition[searchCondition[i].key] = searchCondition[i].value |
|
|
_searchCondition[searchCondition[i].key] = searchCondition[i].value |
|
|
} |
|
|
} |
|
@ -496,7 +511,13 @@ const handleAddTable = () => { |
|
|
tableAllSchemas.value.tableFormColumns.forEach(item => { |
|
|
tableAllSchemas.value.tableFormColumns.forEach(item => { |
|
|
tableFormKeys[item.field] = item.default ? item.default : '' |
|
|
tableFormKeys[item.field] = item.default ? item.default : '' |
|
|
}) |
|
|
}) |
|
|
inpuFocus(tableAllSchemas.value.tableFormColumns[props.indexTableColumn],tableFormKeys,0) |
|
|
if(props.fieldTableColumn!=''){ |
|
|
|
|
|
console.log('handleAddTable',tableAllSchemas.value.tableFormColumns.find(item=>item.field==props.fieldTableColumn)) |
|
|
|
|
|
inpuFocus(tableAllSchemas.value.tableFormColumns.find(item=>item.field==props.fieldTableColumn),tableFormKeys,0) |
|
|
|
|
|
}else{ |
|
|
|
|
|
inpuFocus(tableAllSchemas.value.tableFormColumns[props.indexTableColumn],tableFormKeys,0) |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
}else{ |
|
|
}else{ |
|
|
emit('handleAddTable') |
|
|
emit('handleAddTable') |
|
|
} |
|
|
} |
|
|