diff --git a/src/components/pages/purchase/form/PurchaseRequestForm.tsx b/src/components/pages/purchase/form/PurchaseRequestForm.tsx index 8da24397..dfafae20 100644 --- a/src/components/pages/purchase/form/PurchaseRequestForm.tsx +++ b/src/components/pages/purchase/form/PurchaseRequestForm.tsx @@ -10,8 +10,6 @@ import Button from '@/components/Button'; import TextInput from '@/components/input/TextInput'; import ConfirmationModal from '@/components/modal/ConfirmationModal'; import { useModal } from '@/components/Modal'; -import { FormHeader } from '@/components/helper/form/FormHeader'; -import { FormActions } from '@/components/helper/form/FormActions'; import { PurchaseRequestFormSchema, @@ -260,9 +258,24 @@ const PurchaseRequestForm = ({ return ( <>
- +
+ +

+ {type === 'add' && 'Tambah Purchase Request'} + {type === 'edit' && 'Edit Purchase Request'} + {type === 'detail' && 'Detail Purchase Request'} +

+
{/* Basic Info Card */} @@ -574,16 +587,46 @@ const PurchaseRequestForm = ({ {/* Action buttons */} - - type={type} - formik={formik} - editUrl={ - initialValues - ? `/purchase/detail/edit/?purchaseId=${initialValues.id}` - : undefined - } - onDelete={deletePurchaseRequestClickHandler} - /> +
+ {type !== 'detail' && ( +
+ + + +
+ )} + {type === 'detail' && ( +
+ + + +
+ )} +
+ {purchaseRequestFormErrorMessage && (