🐛[优化] 表单监听子项值监听改为深层次监听,避免值为对象无法监听的问题,修改表单demo加入多选下拉框和 validate-message 描述

This commit is contained in:
xumi
2021-12-20 23:01:10 +08:00
parent f5586dec46
commit 7ff38feec5
2 changed files with 4 additions and 4 deletions

View File

@@ -68,7 +68,7 @@ const ruleItems = computed(()=>{
// 值 计算 和 监听
const filedValue = computed(()=> props.prop ? layForm.model[props.prop] : undefined);
watch(()=>filedValue.value, (val)=> validate());
watch(()=>filedValue.value, (val)=> validate(), {deep: true});
// 错误状态和信息
const errorStatus = ref(false);