From 3c9e627021b31d6ba711324c00ca6514a4ab7b89 Mon Sep 17 00:00:00 2001 From: Blake Matthes Date: Wed, 23 Apr 2025 15:18:58 -0500 Subject: [PATCH] feat(dm): buttons to the nav bar if customs are made --- .../src/components/logistics/dm/DMButtons.tsx | 77 +++---------------- .../src/components/logistics/dm/dmPage.tsx | 21 ++++- 2 files changed, 31 insertions(+), 67 deletions(-) diff --git a/frontend/src/components/logistics/dm/DMButtons.tsx b/frontend/src/components/logistics/dm/DMButtons.tsx index a7a95bd..e35775f 100644 --- a/frontend/src/components/logistics/dm/DMButtons.tsx +++ b/frontend/src/components/logistics/dm/DMButtons.tsx @@ -1,78 +1,23 @@ -import { - DropdownMenu, - DropdownMenuContent, - DropdownMenuItem, - DropdownMenuLabel, - DropdownMenuSeparator, - DropdownMenuTrigger, -} from "@/components/ui/dropdown-menu"; import OrderImport from "./OrderImport"; -import StandardOrderTemplate from "./StandardOrderTemplate"; -import { Button } from "@/components/ui/button"; -import StandardForecastTemplate from "./StandardForecastTemplate"; -import ForecastImport from "./ForecastImport"; import { useSettingStore } from "@/lib/store/useSettings"; export default function DMButtons() { const { settings } = useSettingStore(); const plantToken = settings.filter((n) => n.name === "plantToken"); - console.log(plantToken); + //console.log(plantToken); return ( -
-
- - - - - - - Standard templates and imports - - - - - - - - - - - - - - - - - -
+
{plantToken[0]?.value === "usday1" && ( -
- - - - - - - Custom import templates - - - - - - - - - +
+ +
)}
diff --git a/frontend/src/components/logistics/dm/dmPage.tsx b/frontend/src/components/logistics/dm/dmPage.tsx index 9129530..bf18dd9 100644 --- a/frontend/src/components/logistics/dm/dmPage.tsx +++ b/frontend/src/components/logistics/dm/dmPage.tsx @@ -1,5 +1,9 @@ import { LstCard } from "@/components/extendedUI/LstCard"; import { Separator } from "@/components/ui/separator"; +import OrderImport from "./OrderImport"; +import StandardOrderTemplate from "./StandardOrderTemplate"; +import ForecastImport from "./ForecastImport"; +import StandardForecastTemplate from "./StandardForecastTemplate"; export default function DmPage() { return ( @@ -9,6 +13,13 @@ export default function DmPage() {

Simple instructions for creating/updating orders

+
+ + +
@@ -36,6 +47,7 @@ export default function DmPage() {

Some notes to consider

+