BOD-8 #comment Fixed up part of the vendor edit page. Refetch of list still oustanding.
This commit is contained in:
@@ -4,12 +4,11 @@ import VendorsFormContainer from "../../components/vendors-form/vendors-form.con
|
||||
|
||||
export default function ShopVendorPageComponent({ selectedVendorState }) {
|
||||
//TODO Figure out how to handle the refresh list when saving form
|
||||
|
||||
return (
|
||||
<div>
|
||||
<VendorsListContainer selectedVendorState={selectedVendorState} />
|
||||
<VendorsFormContainer
|
||||
vendorId={selectedVendorState[0] ? selectedVendorState[0].id : null}
|
||||
/>
|
||||
<VendorsFormContainer selectedVendor={selectedVendorState[0]} />
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -7,11 +7,12 @@ export default function ShopVendorPageContainer() {
|
||||
useEffect(() => {
|
||||
document.title = t("titles.shop_vendors");
|
||||
}, [t]);
|
||||
|
||||
const fetchState = useState();
|
||||
const selectedVendorState = useState();
|
||||
return (
|
||||
<div>
|
||||
<ShopVendorPageComponent selectedVendorState={selectedVendorState} />
|
||||
</div>
|
||||
<ShopVendorPageComponent
|
||||
selectedVendorState={selectedVendorState}
|
||||
fetchState={fetchState}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user