From 08fd217ccb9a4fe54883392b494b607165ae1533 Mon Sep 17 00:00:00 2001 From: Keannu Bernasol Date: Thu, 14 Dec 2023 18:13:55 +0800 Subject: [PATCH] Added initial transactions list page and edited technician dashboard component names for better readability --- src/App.tsx | 12 ++++++++++++ ...ianButtons.tsx => TechnicianEquipmentButtons.tsx} | 2 +- .../{TechnicianLogs.tsx => TechnicianLogButtons.tsx} | 2 +- src/Pages/DashboardPage/DashboardPage.tsx | 8 ++++---- .../TransactionsListPage/TransactionsListPage.tsx | 3 +++ 5 files changed, 21 insertions(+), 6 deletions(-) rename src/Components/DashboardPage/{TechnicianButtons.tsx => TechnicianEquipmentButtons.tsx} (99%) rename src/Components/DashboardPage/{TechnicianLogs.tsx => TechnicianLogButtons.tsx} (97%) create mode 100644 src/Pages/TransactionsListPage/TransactionsListPage.tsx diff --git a/src/App.tsx b/src/App.tsx index 605f029..3fdadf4 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -17,6 +17,7 @@ import EquipmentLogsPage from "./Pages/EquipmentLogsPage/EquipmentLogsPage"; import EquipmentInstanceLogsPage from "./Pages/EquipmentInstanceLogsPage/EquipmentInstanceLogsPage"; import EquipmentInstancesFilteredListPage from "./Pages/EquipmentInstancesListPage/EquipmentInstancesFilteredListPage"; import RestrictedPage from "./Components/RestrictedPage/RestrictedPage"; +import TransactionsListPage from "./Pages/TransactionsListPage/TransactionsListPage"; const queryClient = new QueryClient(); const router = createHashRouter([ @@ -84,6 +85,17 @@ const router = createHashRouter([ ), errorElement: , }, + { + path: "/view/transactions", + element: ( + <> + + + + + ), + errorElement: , + }, { path: "/view/equipments/logs", element: ( diff --git a/src/Components/DashboardPage/TechnicianButtons.tsx b/src/Components/DashboardPage/TechnicianEquipmentButtons.tsx similarity index 99% rename from src/Components/DashboardPage/TechnicianButtons.tsx rename to src/Components/DashboardPage/TechnicianEquipmentButtons.tsx index a9aa1a4..da64391 100644 --- a/src/Components/DashboardPage/TechnicianButtons.tsx +++ b/src/Components/DashboardPage/TechnicianEquipmentButtons.tsx @@ -12,7 +12,7 @@ import Popup from "reactjs-popup"; import AddItemModal from "../AddItemModal/AddItemModal"; import AddSKUModal from "../AddSKUModal/AddSKUModal"; import { useState } from "react"; -export default function TechnicianButtons() { +export default function TechnicianEquipmentButtons() { const [addSKUmodalOpen, SetAddSKUModalOpen] = useState(false); const [additemmodalOpen, SetAddItemModalOpen] = useState(false); const navigate = useNavigate(); diff --git a/src/Components/DashboardPage/TechnicianLogs.tsx b/src/Components/DashboardPage/TechnicianLogButtons.tsx similarity index 97% rename from src/Components/DashboardPage/TechnicianLogs.tsx rename to src/Components/DashboardPage/TechnicianLogButtons.tsx index 498c131..74fffe1 100644 --- a/src/Components/DashboardPage/TechnicianLogs.tsx +++ b/src/Components/DashboardPage/TechnicianLogButtons.tsx @@ -4,7 +4,7 @@ import ManageSearchIcon from "@mui/icons-material/ManageSearch"; import styles from "../../styles"; import { colors } from "../../styles"; -export default function TechnicianLogs() { +export default function TechnicianLogButtons() { const navigate = useNavigate(); return ( <> diff --git a/src/Pages/DashboardPage/DashboardPage.tsx b/src/Pages/DashboardPage/DashboardPage.tsx index 1c77d0e..70b0858 100644 --- a/src/Pages/DashboardPage/DashboardPage.tsx +++ b/src/Pages/DashboardPage/DashboardPage.tsx @@ -2,8 +2,8 @@ import Header from "../../Components/Header/Header"; import styles from "../../styles"; import RestrictedComponent from "../../Components/RestrictedComponent/RestrictedComponent"; import TechnicianWidgets from "../../Components/DashboardPage/TechnicianWidgets"; -import TechnicianButtons from "../../Components/DashboardPage/TechnicianButtons"; -import TechnicianLogs from "../../Components/DashboardPage/TechnicianLogs"; +import TechnicianEquipmentButtons from "../../Components/DashboardPage/TechnicianEquipmentButtons"; +import TechnicianLogButtons from "../../Components/DashboardPage/TechnicianLogButtons"; export default function Dashboard() { return (
@@ -12,10 +12,10 @@ export default function Dashboard() { - + - +
); diff --git a/src/Pages/TransactionsListPage/TransactionsListPage.tsx b/src/Pages/TransactionsListPage/TransactionsListPage.tsx new file mode 100644 index 0000000..f22438e --- /dev/null +++ b/src/Pages/TransactionsListPage/TransactionsListPage.tsx @@ -0,0 +1,3 @@ +export default function TransactionsListPage() { + return
{"TransactionsListPage"}
; +}