fix(FE): adding select injection type for positive and negative value

This commit is contained in:
randy-ar
2026-01-26 16:08:23 +07:00
parent 40eaa729ef
commit 85f4a5deaa
4 changed files with 53 additions and 3 deletions
@@ -5,6 +5,7 @@ import * as Yup from 'yup';
export type InjectionFormValues = {
bank_id_option: OptionType | null;
adjustment_date: string;
injection_type?: OptionType | null | undefined;
nominal: string;
note: string;
};
@@ -18,6 +19,7 @@ export const InjectionFormSchema = Yup.object<InjectionFormValues>({
(value) => value !== null && value !== undefined
),
adjustment_date: Yup.string().required('Tanggal penyesuaian wajib diisi'),
injection_type: Yup.mixed().nullable().required('Tipe injeksi wajib diisi'),
nominal: Yup.string().required('Nominal wajib diisi'),
note: Yup.string().required('Catatan wajib diisi'),
});