process/insurance: add fingap.insCost validation
This commit is contained in:
parent
654865e845
commit
d06b6e20d5
@ -101,6 +101,14 @@ export function createValidationSchema({ apolloClient }: ValidationContext) {
|
||||
});
|
||||
}
|
||||
|
||||
if (fingap.insuranceCompany && fingap.insCost < 1000) {
|
||||
ctx.addIssue({
|
||||
code: z.ZodIssueCode.custom,
|
||||
message: `Укажите стоимость ${fingap.policyType}, включаемую в график (>1000)`,
|
||||
path: ['insurance'],
|
||||
});
|
||||
}
|
||||
|
||||
if (
|
||||
!leasingWithoutKasko &&
|
||||
!insDecentral &&
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user