feat: 流程设计数据回显

This commit is contained in:
tony
2022-12-15 08:13:53 +08:00
parent f8a4d8f9a7
commit 8c8dfa1c0f
9 changed files with 119 additions and 219 deletions

View File

@@ -79,15 +79,17 @@ function formBtns(h) {
}
function renderFormItem(h, elementList) {
return elementList.map(scheme => {
const config = scheme.__config__
const layout = layouts[config.layout]
if (elementList) {
return elementList.map(scheme => {
const config = scheme.__config__
const layout = layouts[config.layout]
if (layout) {
return layout.call(this, h, scheme)
}
throw new Error(`没有与${config.layout}匹配的layout`)
})
if (layout) {
return layout.call(this, h, scheme)
}
throw new Error(`没有与${config.layout}匹配的layout`)
})
}
}
function renderChildren(h, scheme) {