diff --git a/src/component/CategoryComponent.js b/src/component/CategoryComponent.js index 70fc4f1..9ac2bbe 100644 --- a/src/component/CategoryComponent.js +++ b/src/component/CategoryComponent.js @@ -195,9 +195,11 @@ export const CategoryComponent = observer((props) => { margin: 0, }} > - + {store.authentication.userData.role === "Admin" && ( + + )}

@@ -209,8 +211,8 @@ export const CategoryComponent = observer((props) => { )} { form.resetFields(); diff --git a/src/component/PartnerComponent.js b/src/component/PartnerComponent.js index b4ea10f..f1f1cc1 100644 --- a/src/component/PartnerComponent.js +++ b/src/component/PartnerComponent.js @@ -329,10 +329,10 @@ export const PartnerComponent = observer((props) => { visible={store.partner.visibleModalPartner} title={ isChangePassword - ? "Change Member Password" + ? "Ganti Password Rekanan" : idData - ? "Edit Partner" - : "Create a new partner" + ? "Edit Rekanan" + : "Buat Rekanan Baru" } okText={idData ? "Edit" : "Create"} cancelText="Batal" diff --git a/src/component/ProductComponent.js b/src/component/ProductComponent.js index 343edc8..da8ac3c 100644 --- a/src/component/ProductComponent.js +++ b/src/component/ProductComponent.js @@ -33,6 +33,7 @@ export const ProductComponent = observer((props) => { const [filterSupplier, setFilterSupplier] = useState([]); const [filterSubCategories, setFilterSubCategories] = useState([]); const modalLoader = useContext(ModalLoaderContext); + const role = store.authentication.userData.role const handleEditButton = (data) => { console.log(data, "isi data"); @@ -61,8 +62,8 @@ export const ProductComponent = observer((props) => { }, { title: "Harga Beli", - dataIndex: "current_price_price", - key: "current_price_price", + dataIndex: "price", + key: "price", render: (text) => new Intl.NumberFormat("id-ID", { style: "currency", @@ -89,6 +90,26 @@ export const ProductComponent = observer((props) => { currency: "IDR", }).format(text), }, + { + title: "Biaya Admin", + dataIndex: "admin_price", + key: "admin_price", + render: (text) => + new Intl.NumberFormat("id-ID", { + style: "currency", + currency: "IDR", + }).format(text), + }, + { + title: "Fee Jual", + dataIndex: "partner_fee", + key: "partner_fee", + render: (text) => + new Intl.NumberFormat("id-ID", { + style: "currency", + currency: "IDR", + }).format(text), + }, { title: "Supplier", dataIndex: "supplier_name", @@ -115,6 +136,7 @@ export const ProductComponent = observer((props) => { { title: "Tindakan", key: "action", + fixed: 'right', render: (text, record) => (