From 75dfd96934b2bf7b4ef9e21d515fcc5a722298ca Mon Sep 17 00:00:00 2001 From: rstubryan Date: Thu, 29 Jan 2026 11:09:30 +0700 Subject: [PATCH] refactor(FE): Replace Badge with simple span and rename adornment prop --- .../recording/form/RecordingForm.tsx | 41 +++---------------- 1 file changed, 6 insertions(+), 35 deletions(-) diff --git a/src/components/pages/production/recording/form/RecordingForm.tsx b/src/components/pages/production/recording/form/RecordingForm.tsx index 13ce9cc9..f3d6d2f9 100644 --- a/src/components/pages/production/recording/form/RecordingForm.tsx +++ b/src/components/pages/production/recording/form/RecordingForm.tsx @@ -1125,16 +1125,9 @@ const RecordingForm = ({ type = 'add', initialValues }: RecordingFormProps) => { } return ( - + Periode {projectFlockKandangLookup.project_flock?.period} - + ); }, [recordedProjectFlockKandangIds, projectFlockKandangLookup]); @@ -1150,33 +1143,11 @@ const RecordingForm = ({ type = 'add', initialValues }: RecordingFormProps) => { const hasOvkFlag = productWarehouse.product.flags?.includes('OVK'); if (hasPakanFlag) { - return ( - - PAKAN - - ); + return PAKAN; } if (hasOvkFlag) { - return ( - - OVK - - ); + return OVK; } return null; @@ -1826,7 +1797,7 @@ const RecordingForm = ({ type = 'add', initialValues }: RecordingFormProps) => { Boolean(formik.errors.kandang_id) } errorMessage={formik.errors.kandang_id as string} - startAdornment={ + inputPrefix={ projectFlockKandangLookup || projectFlockKandangDetail ? getProjectFlockBadgeAdornment() : undefined @@ -2458,7 +2429,7 @@ const RecordingForm = ({ type = 'add', initialValues }: RecordingFormProps) => { !formik.values.project_flock_kandang_id } isClearable={type !== 'detail'} - startAdornment={ + inputPrefix={ stock.product_warehouse_id ? getProductFlagBadgeAdornment( stock.product_warehouse_id