transferred skus

This commit is contained in:
psofia 2024-01-06 15:40:12 +08:00
parent 8cf356ff05
commit 675a1f0716
2 changed files with 66 additions and 4 deletions

View file

@ -99,7 +99,7 @@ export default function TechnicianEquipmentButtons() {
Add Item
</p>
</Button> */}
<Button
{/* <Button
style={{
...styles.flex_column,
...{
@ -129,7 +129,7 @@ export default function TechnicianEquipmentButtons() {
>
Add SKU
</p>
</Button>
</Button> */}
<Button
style={{
...styles.flex_column,
@ -267,7 +267,7 @@ export default function TechnicianEquipmentButtons() {
</p>
</Button> */}
</div>
<Popup
{/* <Popup
open={addSKUmodalOpen}
onClose={() => SetAddSKUModalOpen(false)}
modal
@ -285,7 +285,7 @@ export default function TechnicianEquipmentButtons() {
}}
>
<AddSKUModal />
</Popup>
</Popup> */}
{/* <Popup
open={additemmodalOpen}
onClose={() => SetAddItemModalOpen(false)}

View file

@ -14,10 +14,16 @@ import { colors } from "../../styles";
import EditSKUModal from "../../Components/EditSKUModal/EditSKUModal";
import Popup from "reactjs-popup";
import { useState } from "react";
import NoteAddIcon from "@mui/icons-material/NoteAdd";
import { Button } from "@mui/material";
import AddSKUModal from "../../Components/AddSKUModal/AddSKUModal";
export default function EquipmentListPage() {
const [editmodalOpen, SetEditModalOpen] = useState(false);
const [selectedItem, SetSelectedItem] = useState(0);
const [addSKUmodalOpen, SetAddSKUModalOpen] = useState(false);
const equipments = useQuery({
queryKey: ["equipments"],
queryFn: EquipmentsAPI,
@ -64,7 +70,63 @@ export default function EquipmentListPage() {
minWidth: "100%",
flexWrap: "wrap",
}}
>
<Button
style={{
...styles.flex_column,
...{
alignSelf: "center",
justifyContent: "center",
flexWrap: "wrap",
},
}}
onClick={() => {
SetAddSKUModalOpen(true);
}}
>
<NoteAddIcon
style={{
height: 64,
width: 64,
fill: colors.font_dark,
marginLeft: "1rem",
marginRight: "1rem",
}}
/>
<p
style={{
...styles.text_dark,
...styles.text_M,
}}
>
Add SKU
</p>
</Button>
<Popup
open={addSKUmodalOpen}
onClose={() => SetAddSKUModalOpen(false)}
modal
position={"top center"}
contentStyle={{
width: "32rem",
borderRadius: 16,
borderColor: "grey",
borderStyle: "solid",
borderWidth: 1,
padding: 16,
alignContent: "center",
justifyContent: "center",
textAlign: "center",
}}
>
<AddSKUModal />
</Popup>
<TableContainer
style={{ width: "90%", overflowY: "scroll", marginTop: "2rem" }}
component={Paper}