update
This commit is contained in:
@@ -31,8 +31,9 @@ const fileSuffix = ref('');
|
||||
watch(
|
||||
() => props.modelValue,
|
||||
(val: any) => {
|
||||
fileName.value = val.split('.')[0];
|
||||
fileSuffix.value = val.split('.')[1];
|
||||
const lastDotIndex = val.lastIndexOf('.');
|
||||
fileName.value = val.slice(0, lastDotIndex);
|
||||
fileSuffix.value = val.slice(lastDotIndex + 1);
|
||||
},
|
||||
{
|
||||
immediate: true,
|
||||
|
||||
@@ -84,7 +84,11 @@ watch(
|
||||
setValidateFun(formConfigData.value);
|
||||
setTimeout(() => {
|
||||
nextTick(() => {
|
||||
formRef.value?.resetFields();
|
||||
formConfigData.value.forEach((item: any) => {
|
||||
if (item.inForm && item.validate) {
|
||||
formRef.value?.clearValidate(item.key);
|
||||
}
|
||||
});
|
||||
});
|
||||
}, 0);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user