mirror of
https://github.com/vxcontrol/ncform.git
synced 2026-07-18 16:24:27 -04:00
feat: 业务流程支持 (#5)
* feat: 业务流程的支持 * fix: 流程bug修改 * fix: 修复了隐藏属性会被验证的bug,修复了隐藏的表格还显示的bug
This commit is contained in:
@@ -211,23 +211,18 @@ export default {
|
||||
_get(this.dataFormSchema, 'globalConfig.ignoreRulesWhenHidden', true)
|
||||
) {
|
||||
let isHidden = false
|
||||
let snapIsHidden = ncformUtils.smartAnalyzeVal(schema.ui.hidden, {
|
||||
idxChain: __idxChain,
|
||||
data: {
|
||||
rootData: this.$data.formData,
|
||||
constData: this.dataFormSchema.globalConfig.constants
|
||||
}
|
||||
});
|
||||
if (!schema || schema.ui.process === true || schema.ui.process === undefined) {
|
||||
// 如果开启了忽略隐藏字段规则
|
||||
isHidden = snapIsHidden
|
||||
isHidden = ncformUtils.smartAnalyzeVal(schema.ui.hidden, {
|
||||
idxChain: __idxChain,
|
||||
data: {
|
||||
rootData: this.$data.formData,
|
||||
constData: this.dataFormSchema.globalConfig.constants
|
||||
}
|
||||
});
|
||||
} else {
|
||||
let { constants } = this.dataFormSchema.globalConfig
|
||||
if ((constants.nodeCodeArr.includes(schema.ui.process) || schema.ui.process === constants.nodeUId)) {
|
||||
isHidden = snapIsHidden
|
||||
} else {
|
||||
isHidden = true
|
||||
}
|
||||
isHidden = !(constants.nodeCodeArr.includes(schema.ui.process) || schema.ui.process === constants.nodeUId);
|
||||
}
|
||||
// 如果是隐藏,则忽略校验规则
|
||||
if (isHidden)
|
||||
|
||||
Reference in New Issue
Block a user