Commit 4cca819d authored by 田翔's avatar 田翔

fix: 关联表单必填逻辑问题

parent 3683972f
{
"name": "panda-xform",
"version": "5.9.3",
"description": "5.9.3 增加压缩文件配置默认为压缩",
"version": "5.9.4",
"description": "5.9.4 关联表单必填逻辑问题",
"keywords": [
"panda-xform"
],
......
......@@ -170,7 +170,9 @@ const RelationForm = (props) => {
let tableData = data?.jsonData ? JSON.parse(data?.jsonData) : []
if (Array.isArray(tableData)) {
setDataSource(tableData)
onChange(`${tableData.length}`)
if (tableData.length) {
onChange(`${tableData.length}`)
}
let relationForm = addons.getValue('relationForm') || { configs: [], data: [], table: [] }
window.tableLocal.push({ config, dataSource: tableData, schema })
addons.setValue('relationForm', {
......@@ -180,7 +182,7 @@ const RelationForm = (props) => {
})
} else {
setDataSource([])
onChange(`${0}`)
onChange('')
}
} else {
message.error(msg)
......
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