Commit 3929e6ce authored by 田翔's avatar 田翔

fix: 未知原因出现关联表单配置后无法操作问题

parent de0e8cd0
{
"name": "panda-xform",
"version": "4.0.4",
"description": "4.0.4: 配置SQL问题",
"version": "4.0.5",
"description": "4.0.5: 未知原因出现关联表单配置后无法操作问题",
"keywords": [
"panda-xform"
],
......
......@@ -195,6 +195,11 @@ const TableRender = (props) => {
setDetailShow(true)
}
const back = () => {
setDetailShow(false)
getDataSource()
}
const submit = async () => {
const { formValue, relationForm, errors } = await formRenderRef.current.getValues()
if (errors.length) {
......@@ -305,7 +310,7 @@ const TableRender = (props) => {
</div>
<div className={styles.formBtns}>
<Button
onClick={() => setDetailShow(false)}
onClick={back}
>
返回
</Button>
......
......@@ -2425,23 +2425,18 @@ const advancedWidgets = [
widget: 'checkbox',
default: false,
width: '33%',
props: {
style: {
marginLeft: '10px'
}
}
},
'台账名称': {
title: '台账名称',
type: 'string',
widget: 'AccountName',
required: true
// required: true
},
'映射字段': {
title: '映射字段',
type: 'array',
widget: 'MappedField',
required: true,
// required: true,
default: [],
dependencies: ['台账名称'],
},
......@@ -2456,8 +2451,6 @@ const advancedWidgets = [
'控制规则': {
title: '控制规则',
type: 'string',
displayType: 'row',
labelWidth: 80,
widget: 'ControlRules',
},
groupStyle: {
......
......@@ -157,7 +157,12 @@ export const getVerify = (json) => {
return message.error(`字段【${s}】配置,数据字典必填!`)
}
if (sourceType === '表数据' && !tableName && !fieldName) {
return message.error(`字段【${s}】配置,表名与字段名!`)
return message.error(`字段【${s}】配置,表名与字段名必填!`)
}
}
if (['RelationForm'].includes(widget)) {
if (!child[s]['映射字段'].length || !child[s]['台账名称']) {
return message.error(`字段【${s}】配置,台账名称与映射字段必填!`)
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment