refactor(FE-114): simplify CreateRecordingPayload structure and update validation in RecordingForm

This commit is contained in:
rstubryan
2025-10-24 08:53:41 +07:00
parent 7f5ae94706
commit c30fcd81b2
3 changed files with 31 additions and 289 deletions
+5 -12
View File
@@ -27,26 +27,19 @@ export type Recording = BaseMetadata & BaseRecording;
export type CreateRecordingPayload = {
project_flock_kandang_id: number;
record_datetime: string;
status?: number;
ontime?: boolean;
body_weights?: {
body_weights: {
weight: number;
qty: number;
notes?: string;
}[];
stocks?: {
product_warehouse_id: number;
increase?: number;
decrease?: number;
usage_amount?: number;
notes?: string;
usage_amount: number;
notes: string;
}[];
depletions?: {
product_warehouse_id: number;
condition: string;
product_warehouse_id?: number;
total: number;
notes?: string;
notes: string;
}[];
};