|
|
@ -1,13 +1,13 @@ |
|
|
|
import type { CrudSchema } from '@/hooks/web/useCrudSchemas' |
|
|
|
import { dateFormatter } from '@/utils/formatTime' |
|
|
|
import { getSamplingScheme } from "@/api/qms/aql"; |
|
|
|
import { validateNum } from "@/utils/validator"; |
|
|
|
import {validateNum, validateSampleCode} from "@/utils/validator"; |
|
|
|
|
|
|
|
// 表单校验
|
|
|
|
export const AqlRules = reactive({ |
|
|
|
code: [required], |
|
|
|
inspectionQualification: [required], |
|
|
|
sampleCharacterCode: [required, {max: 1, message: '长度不得超过1个字符', trigger: 'blur' }], |
|
|
|
sampleCharacterCode: [required, {max: 1, message: '长度不得超过1个字符', trigger: 'blur' }, {validator: validateSampleCode, message: '请输入1个大写字母', trigger: 'blur' }], |
|
|
|
sampleQty: [required,{ validator: validateNum, message: '请输入整数', trigger: 'blur' }], |
|
|
|
a0separator010: [required,{ validator: validateNum, message: '请输入整数', trigger: 'blur' }], |
|
|
|
r0separator010: [required,{ validator: validateNum, message: '请输入整数', trigger: 'blur' }], |
|
|
|