|
@@ -1,4 +1,4 @@
|
|
|
-import {validateErrorTip} from '@utils';
|
|
|
+import {formatValidateError} from '@utils';
|
|
|
import {toTypedSchema} from '@vee-validate/zod';
|
|
|
import {useForm} from 'vee-validate';
|
|
|
import {Ref} from 'vue';
|
|
@@ -20,13 +20,13 @@ export function useFormState(isSuccess: Ref<boolean>) {
|
|
|
licenseImage: '',
|
|
|
},
|
|
|
validationSchema: toTypedSchema(object({
|
|
|
- enterprise: string(validateErrorTip('register.errors.enterprise'))
|
|
|
+ enterprise: string(formatValidateError('register.errors.enterprise'))
|
|
|
.min(1, 'register.errors.enterprise'),
|
|
|
- phone: string(validateErrorTip('register.errors.phone'))
|
|
|
+ phone: string(formatValidateError('register.errors.phone'))
|
|
|
.min(1, 'register.errors.phone'),
|
|
|
- idCardImage: string(validateErrorTip('register.errors.idcard'))
|
|
|
+ idCardImage: string(formatValidateError('register.errors.idcard'))
|
|
|
.min(1, 'register.errors.idcard'),
|
|
|
- licenseImage: string(validateErrorTip('register.errors.licenseImage'))
|
|
|
+ licenseImage: string(formatValidateError('register.errors.licenseImage'))
|
|
|
.min(1, 'register.errors.licenseImage'),
|
|
|
})),
|
|
|
});
|