Compare commits
41 Commits
ecb07c7e7c
...
a3732c0208
| Author | SHA1 | Date | |
|---|---|---|---|
| a3732c0208 | |||
| abc39634fb | |||
| dd7299ad76 | |||
| 2343f9387a | |||
| 9a6cec65cd | |||
| 92dc3855b9 | |||
| 6334efe093 | |||
| e9cb3e5db4 | |||
| 8422955d39 | |||
| 06d2f1464b | |||
| a1d526bd52 | |||
| 6ef9626cb7 | |||
| 55cc694a0e | |||
| 3b8296dd54 | |||
| c39a12759f | |||
| 7b0a1d08d2 | |||
| 925776b634 | |||
| 789ea31948 | |||
| f8ba05fbae | |||
| 44f418cfbc | |||
| d65450d5ee | |||
| 8240e9c5d3 | |||
| bb6d1c3bff | |||
| f44e5a87e7 | |||
| b42b8a4c83 | |||
| c741274ffa | |||
| 93693d3093 | |||
| fd49280313 | |||
| 39e5929b46 | |||
| 53520845a8 | |||
| 4fe7eed8ef | |||
| c397e56407 | |||
| ea0610c86b | |||
| 09fd408f6c | |||
| 96c1e4d28a | |||
| 0d4a5ca396 | |||
| 9011b9cb64 | |||
| bc519bcfeb | |||
| f0a1a7ada2 | |||
| 42dcd93d19 | |||
| fdd2024b84 |
54
frontend/package-lock.json
generated
54
frontend/package-lock.json
generated
@@ -23,7 +23,6 @@
|
|||||||
"@radix-ui/react-slot": "^1.1.2",
|
"@radix-ui/react-slot": "^1.1.2",
|
||||||
"@radix-ui/react-tabs": "^1.1.3",
|
"@radix-ui/react-tabs": "^1.1.3",
|
||||||
"@radix-ui/react-tooltip": "^1.1.8",
|
"@radix-ui/react-tooltip": "^1.1.8",
|
||||||
"@tailwindcss/typography": "^0.5.16",
|
|
||||||
"@tailwindcss/vite": "^4.0.15",
|
"@tailwindcss/vite": "^4.0.15",
|
||||||
"@tanstack/react-form": "^1.2.1",
|
"@tanstack/react-form": "^1.2.1",
|
||||||
"@tanstack/react-query": "^5.69.0",
|
"@tanstack/react-query": "^5.69.0",
|
||||||
@@ -2939,21 +2938,6 @@
|
|||||||
"node": ">= 10"
|
"node": ">= 10"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@tailwindcss/typography": {
|
|
||||||
"version": "0.5.16",
|
|
||||||
"resolved": "https://registry.npmjs.org/@tailwindcss/typography/-/typography-0.5.16.tgz",
|
|
||||||
"integrity": "sha512-0wDLwCVF5V3x3b1SGXPCDcdsbDHMBe+lkFzBRaHeLvNi+nrrnZ1lA18u+OTWO8iSWU2GxUOCvlXtDuqftc1oiA==",
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"lodash.castarray": "^4.4.0",
|
|
||||||
"lodash.isplainobject": "^4.0.6",
|
|
||||||
"lodash.merge": "^4.6.2",
|
|
||||||
"postcss-selector-parser": "6.0.10"
|
|
||||||
},
|
|
||||||
"peerDependencies": {
|
|
||||||
"tailwindcss": ">=3.0.0 || insiders || >=4.0.0-alpha.20 || >=4.0.0-beta.1"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@tailwindcss/vite": {
|
"node_modules/@tailwindcss/vite": {
|
||||||
"version": "4.0.15",
|
"version": "4.0.15",
|
||||||
"resolved": "https://registry.npmjs.org/@tailwindcss/vite/-/vite-4.0.15.tgz",
|
"resolved": "https://registry.npmjs.org/@tailwindcss/vite/-/vite-4.0.15.tgz",
|
||||||
@@ -4194,18 +4178,6 @@
|
|||||||
"node": ">= 8"
|
"node": ">= 8"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/cssesc": {
|
|
||||||
"version": "3.0.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/cssesc/-/cssesc-3.0.0.tgz",
|
|
||||||
"integrity": "sha512-/Tb/JcjK111nNScGob5MNtsntNM1aCNUDipB/TkwZFhyDrrE47SOx/18wF2bbjgc3ZzCSKW1T5nt5EbFoAz/Vg==",
|
|
||||||
"license": "MIT",
|
|
||||||
"bin": {
|
|
||||||
"cssesc": "bin/cssesc"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=4"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/csstype": {
|
"node_modules/csstype": {
|
||||||
"version": "3.1.3",
|
"version": "3.1.3",
|
||||||
"resolved": "https://registry.npmjs.org/csstype/-/csstype-3.1.3.tgz",
|
"resolved": "https://registry.npmjs.org/csstype/-/csstype-3.1.3.tgz",
|
||||||
@@ -5746,12 +5718,6 @@
|
|||||||
"integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==",
|
"integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==",
|
||||||
"license": "MIT"
|
"license": "MIT"
|
||||||
},
|
},
|
||||||
"node_modules/lodash.castarray": {
|
|
||||||
"version": "4.4.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/lodash.castarray/-/lodash.castarray-4.4.0.tgz",
|
|
||||||
"integrity": "sha512-aVx8ztPv7/2ULbArGJ2Y42bG1mEQ5mGjpdvrbJcJFU3TbYybe+QlLS4pst9zV52ymy2in1KpFPiZnAOATxD4+Q==",
|
|
||||||
"license": "MIT"
|
|
||||||
},
|
|
||||||
"node_modules/lodash.includes": {
|
"node_modules/lodash.includes": {
|
||||||
"version": "4.3.0",
|
"version": "4.3.0",
|
||||||
"resolved": "https://registry.npmjs.org/lodash.includes/-/lodash.includes-4.3.0.tgz",
|
"resolved": "https://registry.npmjs.org/lodash.includes/-/lodash.includes-4.3.0.tgz",
|
||||||
@@ -5792,6 +5758,7 @@
|
|||||||
"version": "4.6.2",
|
"version": "4.6.2",
|
||||||
"resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.2.tgz",
|
"resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.2.tgz",
|
||||||
"integrity": "sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==",
|
"integrity": "sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==",
|
||||||
|
"dev": true,
|
||||||
"license": "MIT"
|
"license": "MIT"
|
||||||
},
|
},
|
||||||
"node_modules/lodash.once": {
|
"node_modules/lodash.once": {
|
||||||
@@ -6121,19 +6088,6 @@
|
|||||||
"node": "^10 || ^12 || >=14"
|
"node": "^10 || ^12 || >=14"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/postcss-selector-parser": {
|
|
||||||
"version": "6.0.10",
|
|
||||||
"resolved": "https://registry.npmjs.org/postcss-selector-parser/-/postcss-selector-parser-6.0.10.tgz",
|
|
||||||
"integrity": "sha512-IQ7TZdoaqbT+LCpShg46jnZVlhWD2w6iQYAcYXfHARZ7X1t/UGhhceQDs5X0cGqKvYlHNOuv7Oa1xmb0oQuA3w==",
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"cssesc": "^3.0.0",
|
|
||||||
"util-deprecate": "^1.0.2"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=4"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/prelude-ls": {
|
"node_modules/prelude-ls": {
|
||||||
"version": "1.2.1",
|
"version": "1.2.1",
|
||||||
"resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz",
|
"resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz",
|
||||||
@@ -7088,12 +7042,6 @@
|
|||||||
"which-typed-array": "^1.1.2"
|
"which-typed-array": "^1.1.2"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/util-deprecate": {
|
|
||||||
"version": "1.0.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz",
|
|
||||||
"integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==",
|
|
||||||
"license": "MIT"
|
|
||||||
},
|
|
||||||
"node_modules/victory-vendor": {
|
"node_modules/victory-vendor": {
|
||||||
"version": "36.9.2",
|
"version": "36.9.2",
|
||||||
"resolved": "https://registry.npmjs.org/victory-vendor/-/victory-vendor-36.9.2.tgz",
|
"resolved": "https://registry.npmjs.org/victory-vendor/-/victory-vendor-36.9.2.tgz",
|
||||||
|
|||||||
Binary file not shown.
|
Before Width: | Height: | Size: 73 KiB |
BIN
frontend/public/imgs/ordersInExample.png
Normal file
BIN
frontend/public/imgs/ordersInExample.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 29 KiB |
80
frontend/src/components/logistics/dm/DMButtons.tsx
Normal file
80
frontend/src/components/logistics/dm/DMButtons.tsx
Normal file
@@ -0,0 +1,80 @@
|
|||||||
|
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);
|
||||||
|
return (
|
||||||
|
<div className="flex flex-row-reverse">
|
||||||
|
<div className="m-2">
|
||||||
|
<DropdownMenu>
|
||||||
|
<DropdownMenuTrigger asChild>
|
||||||
|
<Button>Standard DM</Button>
|
||||||
|
</DropdownMenuTrigger>
|
||||||
|
<DropdownMenuContent>
|
||||||
|
<DropdownMenuLabel>
|
||||||
|
Standard templates and imports
|
||||||
|
</DropdownMenuLabel>
|
||||||
|
<DropdownMenuSeparator />
|
||||||
|
<DropdownMenuItem>
|
||||||
|
<StandardOrderTemplate />
|
||||||
|
</DropdownMenuItem>
|
||||||
|
<DropdownMenuItem>
|
||||||
|
<OrderImport
|
||||||
|
fileType={"standard"}
|
||||||
|
name={"Standard Order Import"}
|
||||||
|
/>
|
||||||
|
</DropdownMenuItem>
|
||||||
|
<DropdownMenuSeparator />
|
||||||
|
<DropdownMenuItem>
|
||||||
|
<StandardForecastTemplate />
|
||||||
|
</DropdownMenuItem>
|
||||||
|
<DropdownMenuItem>
|
||||||
|
<ForecastImport
|
||||||
|
fileType={"standard"}
|
||||||
|
name={"Standard Forecast Import"}
|
||||||
|
/>
|
||||||
|
</DropdownMenuItem>
|
||||||
|
</DropdownMenuContent>
|
||||||
|
</DropdownMenu>
|
||||||
|
</div>
|
||||||
|
{plantToken[0]?.value === "usday1" && (
|
||||||
|
<div className="m-2">
|
||||||
|
<DropdownMenu>
|
||||||
|
<DropdownMenuTrigger asChild>
|
||||||
|
<Button>Dayton Customs</Button>
|
||||||
|
</DropdownMenuTrigger>
|
||||||
|
<DropdownMenuContent>
|
||||||
|
<DropdownMenuLabel>
|
||||||
|
Custom import templates
|
||||||
|
</DropdownMenuLabel>
|
||||||
|
<DropdownMenuSeparator />
|
||||||
|
|
||||||
|
<DropdownMenuItem>
|
||||||
|
<OrderImport
|
||||||
|
fileType={"abbott"}
|
||||||
|
name={"Abbott truck list"}
|
||||||
|
/>
|
||||||
|
</DropdownMenuItem>
|
||||||
|
<DropdownMenuSeparator />
|
||||||
|
</DropdownMenuContent>
|
||||||
|
</DropdownMenu>
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
}
|
||||||
66
frontend/src/components/logistics/dm/ForecastImport.tsx
Normal file
66
frontend/src/components/logistics/dm/ForecastImport.tsx
Normal file
@@ -0,0 +1,66 @@
|
|||||||
|
import { Button } from "@/components/ui/button";
|
||||||
|
import axios from "axios";
|
||||||
|
import { useRef, useState } from "react";
|
||||||
|
import { toast } from "sonner";
|
||||||
|
|
||||||
|
export default function ForecastImport(props: any) {
|
||||||
|
const fileInputRef: any = useRef(null);
|
||||||
|
const [posting, setPosting] = useState(false);
|
||||||
|
const token = localStorage.getItem("auth_token");
|
||||||
|
//const [fileType, setFileType] = useState("");
|
||||||
|
const importOrders = async (e: any) => {
|
||||||
|
const file = e.target.files[0];
|
||||||
|
if (!file) {
|
||||||
|
toast.error("Missing file please try again");
|
||||||
|
setPosting(false);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
// create the form data with the correct fileType
|
||||||
|
const formData = new FormData();
|
||||||
|
formData.append("postOrders", e.target.files[0]);
|
||||||
|
formData.append("fileType", props.fileType); // extra field
|
||||||
|
// console.log(formData);
|
||||||
|
|
||||||
|
try {
|
||||||
|
const response = await axios.post(
|
||||||
|
"/api/logistics/postforecastin",
|
||||||
|
formData,
|
||||||
|
{
|
||||||
|
headers: {
|
||||||
|
"Content-Type": "multipart/form-data",
|
||||||
|
Authorization: `Bearer ${token}`,
|
||||||
|
},
|
||||||
|
}
|
||||||
|
);
|
||||||
|
console.log("Upload successful:", response.data);
|
||||||
|
toast.success(
|
||||||
|
"File Uploaded, please validate processing in alplaprod 2.0"
|
||||||
|
);
|
||||||
|
setPosting(false);
|
||||||
|
} catch (error) {
|
||||||
|
console.log(error);
|
||||||
|
toast.error("Upload failed");
|
||||||
|
}
|
||||||
|
setPosting(false);
|
||||||
|
};
|
||||||
|
|
||||||
|
const handleButtonClick = () => {
|
||||||
|
setPosting(true);
|
||||||
|
fileInputRef.current.click();
|
||||||
|
};
|
||||||
|
return (
|
||||||
|
<div>
|
||||||
|
<Button onClick={handleButtonClick} disabled={posting}>
|
||||||
|
{props.name}
|
||||||
|
</Button>
|
||||||
|
<input
|
||||||
|
type="file"
|
||||||
|
accept=".xlsx, .xls, .xlsm"
|
||||||
|
ref={fileInputRef}
|
||||||
|
style={{ display: "none" }}
|
||||||
|
onChange={importOrders}
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
}
|
||||||
66
frontend/src/components/logistics/dm/OrderImport.tsx
Normal file
66
frontend/src/components/logistics/dm/OrderImport.tsx
Normal file
@@ -0,0 +1,66 @@
|
|||||||
|
import { Button } from "@/components/ui/button";
|
||||||
|
import axios from "axios";
|
||||||
|
import { useRef, useState } from "react";
|
||||||
|
import { toast } from "sonner";
|
||||||
|
|
||||||
|
export default function OrderImport(props: any) {
|
||||||
|
const fileInputRef: any = useRef(null);
|
||||||
|
const [posting, setPosting] = useState(false);
|
||||||
|
const token = localStorage.getItem("auth_token");
|
||||||
|
//const [fileType, setFileType] = useState("");
|
||||||
|
const importOrders = async (e: any) => {
|
||||||
|
const file = e.target.files[0];
|
||||||
|
if (!file) {
|
||||||
|
toast.error("Missing file please try again");
|
||||||
|
setPosting(false);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
// create the form data with the correct fileType
|
||||||
|
const formData = new FormData();
|
||||||
|
formData.append("postOrders", e.target.files[0]);
|
||||||
|
formData.append("fileType", props.fileType); // extra field
|
||||||
|
// console.log(formData);
|
||||||
|
|
||||||
|
try {
|
||||||
|
const response = await axios.post(
|
||||||
|
"/api/logistics/postbulkorders",
|
||||||
|
formData,
|
||||||
|
{
|
||||||
|
headers: {
|
||||||
|
"Content-Type": "multipart/form-data",
|
||||||
|
Authorization: `Bearer ${token}`,
|
||||||
|
},
|
||||||
|
}
|
||||||
|
);
|
||||||
|
console.log("Upload successful:", response.data);
|
||||||
|
toast.success(
|
||||||
|
"File Uploaded, please validate processing in alplaprod 2.0"
|
||||||
|
);
|
||||||
|
setPosting(false);
|
||||||
|
} catch (error) {
|
||||||
|
console.log(error);
|
||||||
|
toast.error("Upload failed");
|
||||||
|
}
|
||||||
|
setPosting(false);
|
||||||
|
};
|
||||||
|
|
||||||
|
const handleButtonClick = () => {
|
||||||
|
setPosting(true);
|
||||||
|
fileInputRef.current.click();
|
||||||
|
};
|
||||||
|
return (
|
||||||
|
<div>
|
||||||
|
<Button onClick={handleButtonClick} disabled={posting}>
|
||||||
|
{props.name}
|
||||||
|
</Button>
|
||||||
|
<input
|
||||||
|
type="file"
|
||||||
|
accept=".xlsx, .xls, .xlsm"
|
||||||
|
ref={fileInputRef}
|
||||||
|
style={{ display: "none" }}
|
||||||
|
onChange={importOrders}
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
}
|
||||||
@@ -0,0 +1,41 @@
|
|||||||
|
import { Button } from "@/components/ui/button";
|
||||||
|
import axios from "axios";
|
||||||
|
import { format } from "date-fns";
|
||||||
|
import { useState } from "react";
|
||||||
|
import { toast } from "sonner";
|
||||||
|
|
||||||
|
export default function StandardForecastTemplate() {
|
||||||
|
const [template, setTemplate] = useState(false);
|
||||||
|
const getTemplate = async () => {
|
||||||
|
setTemplate(true);
|
||||||
|
try {
|
||||||
|
const res = await axios.get(`/api/logistics/bulkforcasttemplate`, {
|
||||||
|
responseType: "blob",
|
||||||
|
});
|
||||||
|
|
||||||
|
const blob = new Blob([res.data], {
|
||||||
|
type: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
|
||||||
|
});
|
||||||
|
|
||||||
|
const link = document.createElement("a");
|
||||||
|
link.href = window.URL.createObjectURL(blob);
|
||||||
|
link.download = `ForecastTemplate-${format(new Date(Date.now()), "M-d-yyyy")}.xlsx`; // You can make this dynamic
|
||||||
|
document.body.appendChild(link);
|
||||||
|
link.click();
|
||||||
|
|
||||||
|
// Clean up
|
||||||
|
document.body.removeChild(link);
|
||||||
|
window.URL.revokeObjectURL(link.href);
|
||||||
|
toast.success(`Forecast template`);
|
||||||
|
setTemplate(false);
|
||||||
|
} catch (error) {
|
||||||
|
setTemplate(false);
|
||||||
|
toast.error("There was an error getting the template");
|
||||||
|
}
|
||||||
|
};
|
||||||
|
return (
|
||||||
|
<Button onClick={getTemplate} disabled={template}>
|
||||||
|
Standard Forecast Template
|
||||||
|
</Button>
|
||||||
|
);
|
||||||
|
}
|
||||||
@@ -0,0 +1,41 @@
|
|||||||
|
import { Button } from "@/components/ui/button";
|
||||||
|
import axios from "axios";
|
||||||
|
import { format } from "date-fns";
|
||||||
|
import { useState } from "react";
|
||||||
|
import { toast } from "sonner";
|
||||||
|
|
||||||
|
export default function StandardOrderTemplate() {
|
||||||
|
const [template, setTemplate] = useState(false);
|
||||||
|
const getTemplate = async () => {
|
||||||
|
setTemplate(true);
|
||||||
|
try {
|
||||||
|
const res = await axios.get(`/api/logistics/bulkorderstemplate`, {
|
||||||
|
responseType: "blob",
|
||||||
|
});
|
||||||
|
|
||||||
|
const blob = new Blob([res.data], {
|
||||||
|
type: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
|
||||||
|
});
|
||||||
|
|
||||||
|
const link = document.createElement("a");
|
||||||
|
link.href = window.URL.createObjectURL(blob);
|
||||||
|
link.download = `BulkOrderTemplate-${format(new Date(Date.now()), "M-d-yyyy")}.xlsx`; // You can make this dynamic
|
||||||
|
document.body.appendChild(link);
|
||||||
|
link.click();
|
||||||
|
|
||||||
|
// Clean up
|
||||||
|
document.body.removeChild(link);
|
||||||
|
window.URL.revokeObjectURL(link.href);
|
||||||
|
toast.success(`Bulk Order template`);
|
||||||
|
setTemplate(false);
|
||||||
|
} catch (error) {
|
||||||
|
setTemplate(false);
|
||||||
|
toast.error("There was an error getting the tempalte");
|
||||||
|
}
|
||||||
|
};
|
||||||
|
return (
|
||||||
|
<Button onClick={getTemplate} disabled={template}>
|
||||||
|
Standard Order Template
|
||||||
|
</Button>
|
||||||
|
);
|
||||||
|
}
|
||||||
129
frontend/src/components/logistics/dm/dmPage.tsx
Normal file
129
frontend/src/components/logistics/dm/dmPage.tsx
Normal file
@@ -0,0 +1,129 @@
|
|||||||
|
import { LstCard } from "@/components/extendedUI/LstCard";
|
||||||
|
import { Separator } from "@/components/ui/separator";
|
||||||
|
|
||||||
|
export default function DmPage() {
|
||||||
|
return (
|
||||||
|
<div className="flex flex-row gap-2">
|
||||||
|
<LstCard className="w-1/2">
|
||||||
|
<div className="w-96">
|
||||||
|
<h4 className="text-center underline text-2xl">
|
||||||
|
Simple instructions for creating/updating orders
|
||||||
|
</h4>
|
||||||
|
<Separator />
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<ul className="list-disc mr-2">
|
||||||
|
<li>
|
||||||
|
Download the standard template if you have not yet done
|
||||||
|
so, top right click standard, then template.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Add in the orders like you see in the example below.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
When updating orders you are required to have the
|
||||||
|
customerOrderNumber, customerLineNumber, and
|
||||||
|
customerReleaseNumber. Quatity and dates can change.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Once you have all the orders enters click the upload
|
||||||
|
button on the top right
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
|
||||||
|
<Separator className="my-4" />
|
||||||
|
<div className="m-5">
|
||||||
|
<h4 className="text-center underline text-2xl">
|
||||||
|
Some notes to consider
|
||||||
|
</h4>
|
||||||
|
<ul className="list-disc mr-2">
|
||||||
|
<li>
|
||||||
|
No longer need to add in the invoice id, we take the
|
||||||
|
default one.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
You can have as many customers you want in the file
|
||||||
|
and in any order.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Orders created Manually, can not be updated with
|
||||||
|
this process.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
If you desire you can send up to 1000 orders at one
|
||||||
|
time... or more....
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Customer mappings can be added, this means that you
|
||||||
|
can upload your customer file and it will parse
|
||||||
|
onces mapped, you need to request this.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Custom imports will be at the top right under
|
||||||
|
custom, here you will just upload the customer file
|
||||||
|
once mapped.
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
<Separator className="my-4" />
|
||||||
|
<p className="text-center underline text-2xl">Example order</p>
|
||||||
|
<div className="flex justify-center">
|
||||||
|
<img
|
||||||
|
src="/imgs/ordersInExample.png"
|
||||||
|
alt="orders in example"
|
||||||
|
className="w-[680px] h-[280px]"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
</LstCard>
|
||||||
|
<LstCard className="w-1/2">
|
||||||
|
<div className="w-96">
|
||||||
|
<h4 className="text-center underline text-2xl">
|
||||||
|
Simple instructions for creating forecast
|
||||||
|
</h4>
|
||||||
|
<Separator className="my-4" />
|
||||||
|
</div>
|
||||||
|
<div className="m-5">
|
||||||
|
<ul className="list-disc mr-2">
|
||||||
|
<li>
|
||||||
|
Download the template if you have not yet done so.
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
Add in the forecast like you see in the example
|
||||||
|
below.
|
||||||
|
</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
Once you have all the forecast enters click the
|
||||||
|
upload button on the top right
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
<Separator className="my-4" />
|
||||||
|
<div className="m-5">
|
||||||
|
<h4 className="text-center underline text-2xl">
|
||||||
|
Some notes to consider.
|
||||||
|
</h4>
|
||||||
|
<ul className="list-disc mr-2">
|
||||||
|
<li>You can only use one customer at a time.</li>
|
||||||
|
|
||||||
|
<li>
|
||||||
|
If you desire you can send up to 1000 orders at one
|
||||||
|
time...
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
<Separator className="my-4" />
|
||||||
|
<p className="text-center underline text-2xl">
|
||||||
|
Example forecast
|
||||||
|
</p>
|
||||||
|
<div className="flex justify-center">
|
||||||
|
<img
|
||||||
|
src="/imgs/exampleforecast.png"
|
||||||
|
alt="orders in example"
|
||||||
|
className="w-[480px] h-[280px]"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
</LstCard>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
}
|
||||||
@@ -2,7 +2,7 @@ import { Button } from "@/components/ui/button";
|
|||||||
import {
|
import {
|
||||||
Dialog,
|
Dialog,
|
||||||
DialogContent,
|
DialogContent,
|
||||||
DialogDescription,
|
// DialogDescription,
|
||||||
DialogFooter,
|
DialogFooter,
|
||||||
DialogHeader,
|
DialogHeader,
|
||||||
DialogTitle,
|
DialogTitle,
|
||||||
@@ -121,11 +121,11 @@ export default function ManualPrintForm() {
|
|||||||
</DialogTrigger>
|
</DialogTrigger>
|
||||||
<DialogContent className="sm:max-w-[425px]">
|
<DialogContent className="sm:max-w-[425px]">
|
||||||
<DialogHeader>
|
<DialogHeader>
|
||||||
<DialogTitle>Edit profile</DialogTitle>
|
<DialogTitle>Manual Print form</DialogTitle>
|
||||||
<DialogDescription>
|
{/* <DialogDescription>
|
||||||
Make changes to your profile here. Click save when
|
Make changes to your profile here. Click save when
|
||||||
you're done.
|
you're done.
|
||||||
</DialogDescription>
|
</DialogDescription> */}
|
||||||
</DialogHeader>
|
</DialogHeader>
|
||||||
<form onSubmit={handleSubmit(onSubmit)}>
|
<form onSubmit={handleSubmit(onSubmit)}>
|
||||||
<p>
|
<p>
|
||||||
|
|||||||
@@ -23,6 +23,13 @@ export const SessionProvider = ({
|
|||||||
fetchUserRoles();
|
fetchUserRoles();
|
||||||
fetchSubModules();
|
fetchSubModules();
|
||||||
}, []);
|
}, []);
|
||||||
|
|
||||||
|
//temp
|
||||||
|
localStorage.removeItem("ally-supports-cache");
|
||||||
|
localStorage.removeItem("auth-storage");
|
||||||
|
localStorage.removeItem("nextauth.message");
|
||||||
|
localStorage.removeItem("prod");
|
||||||
|
localStorage.removeItem("card-storage");
|
||||||
return (
|
return (
|
||||||
<QueryClientProvider client={queryClient}>
|
<QueryClientProvider client={queryClient}>
|
||||||
{children}
|
{children}
|
||||||
|
|||||||
@@ -5,12 +5,6 @@ import { useEffect } from "react";
|
|||||||
const fetchSession = async () => {
|
const fetchSession = async () => {
|
||||||
const token = localStorage.getItem("auth_token");
|
const token = localStorage.getItem("auth_token");
|
||||||
|
|
||||||
//temp
|
|
||||||
localStorage.removeItem("ally-supports-cache");
|
|
||||||
localStorage.removeItem("auth-storage");
|
|
||||||
localStorage.removeItem("nextauth.message");
|
|
||||||
localStorage.removeItem("prod");
|
|
||||||
|
|
||||||
if (!token) {
|
if (!token) {
|
||||||
throw new Error("No token found");
|
throw new Error("No token found");
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -43,7 +43,7 @@ export const useCardStore = create<CardStore>()(
|
|||||||
cards: state.cards.filter((card) => card.name !== name),
|
cards: state.cards.filter((card) => card.name !== name),
|
||||||
})),
|
})),
|
||||||
}),
|
}),
|
||||||
{ name: "card-storage" }
|
{ name: "cards" }
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -31,6 +31,7 @@ import { Route as ocmeCyclecountIndexImport } from './routes/(ocme)/cyclecount/i
|
|||||||
import { Route as logisticsSiloAdjustmentsIndexImport } from './routes/(logistics)/siloAdjustments/index'
|
import { Route as logisticsSiloAdjustmentsIndexImport } from './routes/(logistics)/siloAdjustments/index'
|
||||||
import { Route as logisticsOpenOrdersIndexImport } from './routes/(logistics)/openOrders/index'
|
import { Route as logisticsOpenOrdersIndexImport } from './routes/(logistics)/openOrders/index'
|
||||||
import { Route as logisticsMaterialHelperIndexImport } from './routes/(logistics)/materialHelper/index'
|
import { Route as logisticsMaterialHelperIndexImport } from './routes/(logistics)/materialHelper/index'
|
||||||
|
import { Route as logisticsDmIndexImport } from './routes/(logistics)/dm/index'
|
||||||
import { Route as EomArticleAvImport } from './routes/_eom/article/$av'
|
import { Route as EomArticleAvImport } from './routes/_eom/article/$av'
|
||||||
import { Route as logisticsSiloAdjustmentsHistImport } from './routes/(logistics)/siloAdjustments/$hist'
|
import { Route as logisticsSiloAdjustmentsHistImport } from './routes/(logistics)/siloAdjustments/$hist'
|
||||||
import { Route as logisticsMaterialHelperSiloLinkIndexImport } from './routes/(logistics)/materialHelper/siloLink/index'
|
import { Route as logisticsMaterialHelperSiloLinkIndexImport } from './routes/(logistics)/materialHelper/siloLink/index'
|
||||||
@@ -158,6 +159,12 @@ const logisticsMaterialHelperIndexRoute =
|
|||||||
getParentRoute: () => rootRoute,
|
getParentRoute: () => rootRoute,
|
||||||
} as any)
|
} as any)
|
||||||
|
|
||||||
|
const logisticsDmIndexRoute = logisticsDmIndexImport.update({
|
||||||
|
id: '/(logistics)/dm/',
|
||||||
|
path: '/dm/',
|
||||||
|
getParentRoute: () => rootRoute,
|
||||||
|
} as any)
|
||||||
|
|
||||||
const EomArticleAvRoute = EomArticleAvImport.update({
|
const EomArticleAvRoute = EomArticleAvImport.update({
|
||||||
id: '/article/$av',
|
id: '/article/$av',
|
||||||
path: '/article/$av',
|
path: '/article/$av',
|
||||||
@@ -322,6 +329,13 @@ declare module '@tanstack/react-router' {
|
|||||||
preLoaderRoute: typeof EomArticleAvImport
|
preLoaderRoute: typeof EomArticleAvImport
|
||||||
parentRoute: typeof EomImport
|
parentRoute: typeof EomImport
|
||||||
}
|
}
|
||||||
|
'/(logistics)/dm/': {
|
||||||
|
id: '/(logistics)/dm/'
|
||||||
|
path: '/dm'
|
||||||
|
fullPath: '/dm'
|
||||||
|
preLoaderRoute: typeof logisticsDmIndexImport
|
||||||
|
parentRoute: typeof rootRoute
|
||||||
|
}
|
||||||
'/(logistics)/materialHelper/': {
|
'/(logistics)/materialHelper/': {
|
||||||
id: '/(logistics)/materialHelper/'
|
id: '/(logistics)/materialHelper/'
|
||||||
path: '/materialHelper'
|
path: '/materialHelper'
|
||||||
@@ -435,6 +449,7 @@ export interface FileRoutesByFullPath {
|
|||||||
'/ocp': typeof OcpIndexRoute
|
'/ocp': typeof OcpIndexRoute
|
||||||
'/siloAdjustments/$hist': typeof logisticsSiloAdjustmentsHistRoute
|
'/siloAdjustments/$hist': typeof logisticsSiloAdjustmentsHistRoute
|
||||||
'/article/$av': typeof EomArticleAvRoute
|
'/article/$av': typeof EomArticleAvRoute
|
||||||
|
'/dm': typeof logisticsDmIndexRoute
|
||||||
'/materialHelper': typeof logisticsMaterialHelperIndexRoute
|
'/materialHelper': typeof logisticsMaterialHelperIndexRoute
|
||||||
'/openOrders': typeof logisticsOpenOrdersIndexRoute
|
'/openOrders': typeof logisticsOpenOrdersIndexRoute
|
||||||
'/siloAdjustments': typeof logisticsSiloAdjustmentsIndexRoute
|
'/siloAdjustments': typeof logisticsSiloAdjustmentsIndexRoute
|
||||||
@@ -461,6 +476,7 @@ export interface FileRoutesByTo {
|
|||||||
'/ocp': typeof OcpIndexRoute
|
'/ocp': typeof OcpIndexRoute
|
||||||
'/siloAdjustments/$hist': typeof logisticsSiloAdjustmentsHistRoute
|
'/siloAdjustments/$hist': typeof logisticsSiloAdjustmentsHistRoute
|
||||||
'/article/$av': typeof EomArticleAvRoute
|
'/article/$av': typeof EomArticleAvRoute
|
||||||
|
'/dm': typeof logisticsDmIndexRoute
|
||||||
'/materialHelper': typeof logisticsMaterialHelperIndexRoute
|
'/materialHelper': typeof logisticsMaterialHelperIndexRoute
|
||||||
'/openOrders': typeof logisticsOpenOrdersIndexRoute
|
'/openOrders': typeof logisticsOpenOrdersIndexRoute
|
||||||
'/siloAdjustments': typeof logisticsSiloAdjustmentsIndexRoute
|
'/siloAdjustments': typeof logisticsSiloAdjustmentsIndexRoute
|
||||||
@@ -490,6 +506,7 @@ export interface FileRoutesById {
|
|||||||
'/ocp/': typeof OcpIndexRoute
|
'/ocp/': typeof OcpIndexRoute
|
||||||
'/(logistics)/siloAdjustments/$hist': typeof logisticsSiloAdjustmentsHistRoute
|
'/(logistics)/siloAdjustments/$hist': typeof logisticsSiloAdjustmentsHistRoute
|
||||||
'/_eom/article/$av': typeof EomArticleAvRoute
|
'/_eom/article/$av': typeof EomArticleAvRoute
|
||||||
|
'/(logistics)/dm/': typeof logisticsDmIndexRoute
|
||||||
'/(logistics)/materialHelper/': typeof logisticsMaterialHelperIndexRoute
|
'/(logistics)/materialHelper/': typeof logisticsMaterialHelperIndexRoute
|
||||||
'/(logistics)/openOrders/': typeof logisticsOpenOrdersIndexRoute
|
'/(logistics)/openOrders/': typeof logisticsOpenOrdersIndexRoute
|
||||||
'/(logistics)/siloAdjustments/': typeof logisticsSiloAdjustmentsIndexRoute
|
'/(logistics)/siloAdjustments/': typeof logisticsSiloAdjustmentsIndexRoute
|
||||||
@@ -518,6 +535,7 @@ export interface FileRouteTypes {
|
|||||||
| '/ocp'
|
| '/ocp'
|
||||||
| '/siloAdjustments/$hist'
|
| '/siloAdjustments/$hist'
|
||||||
| '/article/$av'
|
| '/article/$av'
|
||||||
|
| '/dm'
|
||||||
| '/materialHelper'
|
| '/materialHelper'
|
||||||
| '/openOrders'
|
| '/openOrders'
|
||||||
| '/siloAdjustments'
|
| '/siloAdjustments'
|
||||||
@@ -543,6 +561,7 @@ export interface FileRouteTypes {
|
|||||||
| '/ocp'
|
| '/ocp'
|
||||||
| '/siloAdjustments/$hist'
|
| '/siloAdjustments/$hist'
|
||||||
| '/article/$av'
|
| '/article/$av'
|
||||||
|
| '/dm'
|
||||||
| '/materialHelper'
|
| '/materialHelper'
|
||||||
| '/openOrders'
|
| '/openOrders'
|
||||||
| '/siloAdjustments'
|
| '/siloAdjustments'
|
||||||
@@ -570,6 +589,7 @@ export interface FileRouteTypes {
|
|||||||
| '/ocp/'
|
| '/ocp/'
|
||||||
| '/(logistics)/siloAdjustments/$hist'
|
| '/(logistics)/siloAdjustments/$hist'
|
||||||
| '/_eom/article/$av'
|
| '/_eom/article/$av'
|
||||||
|
| '/(logistics)/dm/'
|
||||||
| '/(logistics)/materialHelper/'
|
| '/(logistics)/materialHelper/'
|
||||||
| '/(logistics)/openOrders/'
|
| '/(logistics)/openOrders/'
|
||||||
| '/(logistics)/siloAdjustments/'
|
| '/(logistics)/siloAdjustments/'
|
||||||
@@ -590,6 +610,7 @@ export interface RootRouteChildren {
|
|||||||
LoginRoute: typeof LoginRoute
|
LoginRoute: typeof LoginRoute
|
||||||
OcpIndexRoute: typeof OcpIndexRoute
|
OcpIndexRoute: typeof OcpIndexRoute
|
||||||
logisticsSiloAdjustmentsHistRoute: typeof logisticsSiloAdjustmentsHistRoute
|
logisticsSiloAdjustmentsHistRoute: typeof logisticsSiloAdjustmentsHistRoute
|
||||||
|
logisticsDmIndexRoute: typeof logisticsDmIndexRoute
|
||||||
logisticsMaterialHelperIndexRoute: typeof logisticsMaterialHelperIndexRoute
|
logisticsMaterialHelperIndexRoute: typeof logisticsMaterialHelperIndexRoute
|
||||||
logisticsOpenOrdersIndexRoute: typeof logisticsOpenOrdersIndexRoute
|
logisticsOpenOrdersIndexRoute: typeof logisticsOpenOrdersIndexRoute
|
||||||
logisticsSiloAdjustmentsIndexRoute: typeof logisticsSiloAdjustmentsIndexRoute
|
logisticsSiloAdjustmentsIndexRoute: typeof logisticsSiloAdjustmentsIndexRoute
|
||||||
@@ -609,6 +630,7 @@ const rootRouteChildren: RootRouteChildren = {
|
|||||||
LoginRoute: LoginRoute,
|
LoginRoute: LoginRoute,
|
||||||
OcpIndexRoute: OcpIndexRoute,
|
OcpIndexRoute: OcpIndexRoute,
|
||||||
logisticsSiloAdjustmentsHistRoute: logisticsSiloAdjustmentsHistRoute,
|
logisticsSiloAdjustmentsHistRoute: logisticsSiloAdjustmentsHistRoute,
|
||||||
|
logisticsDmIndexRoute: logisticsDmIndexRoute,
|
||||||
logisticsMaterialHelperIndexRoute: logisticsMaterialHelperIndexRoute,
|
logisticsMaterialHelperIndexRoute: logisticsMaterialHelperIndexRoute,
|
||||||
logisticsOpenOrdersIndexRoute: logisticsOpenOrdersIndexRoute,
|
logisticsOpenOrdersIndexRoute: logisticsOpenOrdersIndexRoute,
|
||||||
logisticsSiloAdjustmentsIndexRoute: logisticsSiloAdjustmentsIndexRoute,
|
logisticsSiloAdjustmentsIndexRoute: logisticsSiloAdjustmentsIndexRoute,
|
||||||
@@ -640,6 +662,7 @@ export const routeTree = rootRoute
|
|||||||
"/login",
|
"/login",
|
||||||
"/ocp/",
|
"/ocp/",
|
||||||
"/(logistics)/siloAdjustments/$hist",
|
"/(logistics)/siloAdjustments/$hist",
|
||||||
|
"/(logistics)/dm/",
|
||||||
"/(logistics)/materialHelper/",
|
"/(logistics)/materialHelper/",
|
||||||
"/(logistics)/openOrders/",
|
"/(logistics)/openOrders/",
|
||||||
"/(logistics)/siloAdjustments/",
|
"/(logistics)/siloAdjustments/",
|
||||||
@@ -727,6 +750,9 @@ export const routeTree = rootRoute
|
|||||||
"filePath": "_eom/article/$av.tsx",
|
"filePath": "_eom/article/$av.tsx",
|
||||||
"parent": "/_eom"
|
"parent": "/_eom"
|
||||||
},
|
},
|
||||||
|
"/(logistics)/dm/": {
|
||||||
|
"filePath": "(logistics)/dm/index.tsx"
|
||||||
|
},
|
||||||
"/(logistics)/materialHelper/": {
|
"/(logistics)/materialHelper/": {
|
||||||
"filePath": "(logistics)/materialHelper/index.tsx"
|
"filePath": "(logistics)/materialHelper/index.tsx"
|
||||||
},
|
},
|
||||||
|
|||||||
28
frontend/src/routes/(logistics)/dm/index.tsx
Normal file
28
frontend/src/routes/(logistics)/dm/index.tsx
Normal file
@@ -0,0 +1,28 @@
|
|||||||
|
import DmPage from "@/components/logistics/dm/dmPage";
|
||||||
|
import { createFileRoute, redirect } from "@tanstack/react-router";
|
||||||
|
|
||||||
|
export const Route = createFileRoute("/(logistics)/dm/")({
|
||||||
|
component: RouteComponent,
|
||||||
|
beforeLoad: async () => {
|
||||||
|
const auth = localStorage.getItem("auth_token");
|
||||||
|
if (!auth) {
|
||||||
|
throw redirect({
|
||||||
|
to: "/login",
|
||||||
|
search: {
|
||||||
|
// Use the current location to power a redirect after login
|
||||||
|
// (Do not use `router.state.resolvedLocation` as it can
|
||||||
|
// potentially lag behind the actual current location)
|
||||||
|
redirect: location.pathname + location.search,
|
||||||
|
},
|
||||||
|
});
|
||||||
|
}
|
||||||
|
},
|
||||||
|
});
|
||||||
|
|
||||||
|
function RouteComponent() {
|
||||||
|
return (
|
||||||
|
<div>
|
||||||
|
<DmPage />
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
}
|
||||||
@@ -27,6 +27,7 @@ import { useSession } from "@/hooks/useSession";
|
|||||||
import { useLogout } from "@/hooks/useLogout";
|
import { useLogout } from "@/hooks/useLogout";
|
||||||
import ExportInventoryData from "@/components/logistics/warehouse/ExportInventoryData";
|
import ExportInventoryData from "@/components/logistics/warehouse/ExportInventoryData";
|
||||||
import { AddCards } from "@/components/dashboard/AddCards";
|
import { AddCards } from "@/components/dashboard/AddCards";
|
||||||
|
import DMButtons from "@/components/logistics/dm/DMButtons";
|
||||||
//import { AddCards } from "@/components/dashboard/AddCards";
|
//import { AddCards } from "@/components/dashboard/AddCards";
|
||||||
|
|
||||||
// same as the layout
|
// same as the layout
|
||||||
@@ -44,12 +45,19 @@ export const Route = createRootRoute({
|
|||||||
<ThemeProvider>
|
<ThemeProvider>
|
||||||
<nav className="flex justify-end w-full shadow ">
|
<nav className="flex justify-end w-full shadow ">
|
||||||
<div className="m-2 flex flex-row">
|
<div className="m-2 flex flex-row">
|
||||||
|
{/* Inventory section */}
|
||||||
{location.pathname === "/" && (
|
{location.pathname === "/" && (
|
||||||
<div className="m-auto pr-2 flex flex-row gap-2">
|
<div className="m-auto pr-2 flex flex-row gap-2">
|
||||||
<ExportInventoryData />
|
<ExportInventoryData />
|
||||||
<AddCards />
|
<AddCards />
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
|
{/* Demand mgt section this should also include plant token stuff */}
|
||||||
|
{location.pathname === "/dm" && (
|
||||||
|
<div className="m-auto pr-2 flex flex-row gap-2">
|
||||||
|
<DMButtons />
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
<div className="m-1">
|
<div className="m-1">
|
||||||
<ModeToggle />
|
<ModeToggle />
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -1,8 +1,12 @@
|
|||||||
import { addHours, format } from "date-fns";
|
import { addHours } from "date-fns";
|
||||||
|
import { format } from "date-fns-tz";
|
||||||
|
|
||||||
export const fixTime = (date: any) => {
|
export const fixTime = (date: any) => {
|
||||||
|
/**
|
||||||
|
* This fix is when it comes directly from lst
|
||||||
|
*/
|
||||||
if (!date) return;
|
if (!date) return;
|
||||||
// const strippedDate = date?.replace("Z", ""); // Remove Z
|
//const strippedDate = date?.replace("Z", ""); // Remove Z
|
||||||
//return format(strippedDate, "MM/dd/yyyy hh:mm a");
|
//return format(strippedDate, "MM/dd/yyyy hh:mm a");
|
||||||
|
|
||||||
const rawDate = new Date(date).toISOString();
|
const rawDate = new Date(date).toISOString();
|
||||||
@@ -12,6 +16,6 @@ export const fixTime = (date: any) => {
|
|||||||
|
|
||||||
return format(
|
return format(
|
||||||
addHours(rawDate, offsetHours).toISOString(),
|
addHours(rawDate, offsetHours).toISOString(),
|
||||||
"MM/dd/yyyy hh:mm a"
|
"MM/dd/yyyy hh:mm"
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -39,7 +39,7 @@ export function InvTable<TData, TValue>({
|
|||||||
const [sorting, setSorting] = useState<SortingState>([]);
|
const [sorting, setSorting] = useState<SortingState>([]);
|
||||||
const [pagination, setPagination] = useState({
|
const [pagination, setPagination] = useState({
|
||||||
pageIndex: 0, //initial page index
|
pageIndex: 0, //initial page index
|
||||||
pageSize: 5, //default page size
|
pageSize: 500, //default page size
|
||||||
});
|
});
|
||||||
const table = useReactTable({
|
const table = useReactTable({
|
||||||
data,
|
data,
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
import { fixTime } from "@/utils/fixTime";
|
//import { fixTime } from "@/utils/fixTime";
|
||||||
import { ColumnDef } from "@tanstack/react-table";
|
import { ColumnDef } from "@tanstack/react-table";
|
||||||
|
import { format } from "date-fns-tz";
|
||||||
|
|
||||||
// This type is used to define the shape of our data.
|
// This type is used to define the shape of our data.
|
||||||
// You can use a Zod schema here if you want.
|
// You can use a Zod schema here if you want.
|
||||||
@@ -33,9 +34,14 @@ export const labelolumns: ColumnDef<Adjustmnets>[] = [
|
|||||||
header: "Label Date",
|
header: "Label Date",
|
||||||
cell: ({ row }) => {
|
cell: ({ row }) => {
|
||||||
if (row.getValue("upd_date")) {
|
if (row.getValue("upd_date")) {
|
||||||
const correctDate = fixTime(row.getValue("upd_date"));
|
const correctDate: any = row.getValue("upd_date");
|
||||||
|
const strippedDate = correctDate.replace("Z", ""); // Remove Z
|
||||||
|
const formattedDate = format(
|
||||||
|
strippedDate,
|
||||||
|
"MM/dd/yyyy hh:mm a"
|
||||||
|
);
|
||||||
return (
|
return (
|
||||||
<div className="text-left font-medium">{correctDate}</div>
|
<div className="text-left font-medium">{formattedDate}</div>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -35,7 +35,7 @@ export function hasPageAccess(
|
|||||||
// get only the module in the user profile
|
// get only the module in the user profile
|
||||||
//console.log(user);
|
//console.log(user);
|
||||||
const userRole = user?.roles.filter((role) => role.module_id === module_id);
|
const userRole = user?.roles.filter((role) => role.module_id === module_id);
|
||||||
console.log(userRole[0]?.role);
|
//console.log(userRole[0]?.role);
|
||||||
// if (role.includes(userRole[0]?.role)) {
|
// if (role.includes(userRole[0]?.role)) {
|
||||||
|
|
||||||
// return true};
|
// return true};
|
||||||
|
|||||||
@@ -35,7 +35,7 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"admConfig": {
|
"admConfig": {
|
||||||
"build": 260,
|
"build": 287,
|
||||||
"oldBuild": "backend-0.1.3.zip"
|
"oldBuild": "backend-0.1.3.zip"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
|
|||||||
@@ -189,6 +189,7 @@ const port =
|
|||||||
? process.env.VITE_SERVER_PORT
|
? process.env.VITE_SERVER_PORT
|
||||||
: process.env.PROD_PORT;
|
: process.env.PROD_PORT;
|
||||||
|
|
||||||
|
const ocmeport = process.env.OCME_PORT;
|
||||||
serve(
|
serve(
|
||||||
{
|
{
|
||||||
fetch: app.fetch,
|
fetch: app.fetch,
|
||||||
@@ -205,4 +206,27 @@ serve(
|
|||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Only for ocme until we get them switched over to the single port setup.
|
||||||
|
*/
|
||||||
|
const setting = await db.select().from(settings);
|
||||||
|
const isActive = setting.filter((n) => n.name === "ocmeService");
|
||||||
|
if (ocmeport && isActive[0]?.value === "1") {
|
||||||
|
serve(
|
||||||
|
{
|
||||||
|
fetch: app.fetch,
|
||||||
|
port: Number(ocmeport),
|
||||||
|
hostname: "0.0.0.0",
|
||||||
|
},
|
||||||
|
(info) => {
|
||||||
|
createLog(
|
||||||
|
"info",
|
||||||
|
"LST",
|
||||||
|
"server",
|
||||||
|
`Ocme section is listening on http://${info.address}:${info.port}`
|
||||||
|
);
|
||||||
|
}
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
export type AppRoutes = typeof appRoutes;
|
export type AppRoutes = typeof appRoutes;
|
||||||
|
|||||||
@@ -105,7 +105,7 @@ app.openapi(
|
|||||||
return c.json({
|
return c.json({
|
||||||
success: true,
|
success: true,
|
||||||
message: "All Current Active Querys.",
|
message: "All Current Active Querys.",
|
||||||
sheetVersion: 2.5,
|
sheetVersion: 2.7,
|
||||||
data: current,
|
data: current,
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
import {and, eq, inArray, lte, ne, sql} from "drizzle-orm";
|
import { and, eq, inArray, lte, ne, sql } from "drizzle-orm";
|
||||||
import {db} from "../../../../database/dbclient.js";
|
import { db } from "../../../../database/dbclient.js";
|
||||||
import {logs} from "../../../../database/schema/logs.js";
|
import { logs } from "../../../../database/schema/logs.js";
|
||||||
import {createLog} from "../logger.js";
|
import { createLog } from "../logger.js";
|
||||||
|
|
||||||
export const logCleanup = async () => {
|
export const logCleanup = async () => {
|
||||||
/**
|
/**
|
||||||
@@ -12,15 +12,15 @@ export const logCleanup = async () => {
|
|||||||
try {
|
try {
|
||||||
// clear info logs older than 3 days
|
// clear info logs older than 3 days
|
||||||
const delLogs = await db
|
const delLogs = await db
|
||||||
.delete(logs)
|
.delete(logs)
|
||||||
.where(
|
.where(
|
||||||
and(
|
and(
|
||||||
lte(logs.created_at, sql`NOW() - INTERVAL '3 days'`),
|
lte(logs.created_at, sql`NOW() - INTERVAL '3 days'`),
|
||||||
inArray(logs.service, ["server", "tcp", "sqlProd", "globalutils"]),
|
//inArray(logs.service, ["server", "tcp", "sqlProd", "globalutils","notify", "logger", "serverupdater"]),
|
||||||
eq(logs.level, "30")
|
eq(logs.level, "info")
|
||||||
|
)
|
||||||
)
|
)
|
||||||
)
|
.returning({ name: logs.message });
|
||||||
.returning({name: logs.message});
|
|
||||||
createLog(
|
createLog(
|
||||||
"info",
|
"info",
|
||||||
"lst",
|
"lst",
|
||||||
@@ -28,21 +28,26 @@ export const logCleanup = async () => {
|
|||||||
`${delLogs.length} Server logs were just deleted that were older than 3 days`
|
`${delLogs.length} Server logs were just deleted that were older than 3 days`
|
||||||
);
|
);
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
createLog("error", "lst", "logger", `There was an error deleteing server logs. ${error}`);
|
createLog(
|
||||||
|
"error",
|
||||||
|
"lst",
|
||||||
|
"logger",
|
||||||
|
`There was an error deleteing server logs. ${error}`
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
// clear all remaining logs ne to info.
|
// clear all remaining logs ne to info.
|
||||||
const delLogs = await db
|
const delLogs = await db
|
||||||
.delete(logs)
|
.delete(logs)
|
||||||
.where(
|
.where(
|
||||||
and(
|
and(
|
||||||
lte(logs.created_at, sql`NOW() - INTERVAL '7 days'`),
|
lte(logs.created_at, sql`NOW() - INTERVAL '7 days'`),
|
||||||
inArray(logs.service, ["server", "tcp", "sqlProd", "globalutils"]),
|
//inArray(logs.service, ["server", "tcp", "sqlProd", "globalutils", "notify", "logger", "serverupdater"]),
|
||||||
ne(logs.level, "30")
|
ne(logs.level, "info")
|
||||||
|
)
|
||||||
)
|
)
|
||||||
)
|
.returning({ name: logs.message });
|
||||||
.returning({name: logs.message});
|
|
||||||
createLog(
|
createLog(
|
||||||
"info",
|
"info",
|
||||||
"lst",
|
"lst",
|
||||||
@@ -50,6 +55,11 @@ export const logCleanup = async () => {
|
|||||||
`${delLogs.length} Server logs were just deleted that were older than 7 days`
|
`${delLogs.length} Server logs were just deleted that were older than 7 days`
|
||||||
);
|
);
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
createLog("error", "lst", "logger", `There was an error deleteing server logs. ${error}`);
|
createLog(
|
||||||
|
"error",
|
||||||
|
"lst",
|
||||||
|
"logger",
|
||||||
|
`There was an error deleteing server logs. ${error}`
|
||||||
|
);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -28,6 +28,10 @@ export default async function qualityBlockingMonitor(notifyData: any) {
|
|||||||
.where(eq(notifications.name, notifyData.name))
|
.where(eq(notifications.name, notifyData.name))
|
||||||
);
|
);
|
||||||
|
|
||||||
|
if (notiError) {
|
||||||
|
throw Error(`${JSON.stringify(notiError)}`);
|
||||||
|
}
|
||||||
|
|
||||||
const notiData: any = noti;
|
const notiData: any = noti;
|
||||||
const blockingOrders = notiData[0]?.notifiySettings.sentBlockingOrders.map(
|
const blockingOrders = notiData[0]?.notifiySettings.sentBlockingOrders.map(
|
||||||
(l: any) => {
|
(l: any) => {
|
||||||
|
|||||||
@@ -81,7 +81,9 @@ export const cycleCount = async (lane: any, user: User) => {
|
|||||||
const postCount = {
|
const postCount = {
|
||||||
laneId: ocme[0].alpla_laneID,
|
laneId: ocme[0].alpla_laneID,
|
||||||
warehouseName: "",
|
warehouseName: "",
|
||||||
laneName: alplaStock[0].alpla_laneDescription,
|
laneName: alplaStock[0]?.alpla_laneDescription
|
||||||
|
? alplaStock[0].alpla_laneDescription
|
||||||
|
: ocme[0].alpla_laneDescription,
|
||||||
good: !combineBoth.every(
|
good: !combineBoth.every(
|
||||||
(s) => !s.info.includes("Validate") || !s.info.includes("sent")
|
(s) => !s.info.includes("Validate") || !s.info.includes("sent")
|
||||||
),
|
),
|
||||||
|
|||||||
@@ -16,43 +16,24 @@ import manualTrigger from "./route/triggerCamera.js";
|
|||||||
const app = new OpenAPIHono();
|
const app = new OpenAPIHono();
|
||||||
const port = process.env.OCME_PORT;
|
const port = process.env.OCME_PORT;
|
||||||
const routes = [
|
const routes = [
|
||||||
getInfo,
|
getInfo,
|
||||||
postRunningNr,
|
postRunningNr,
|
||||||
postsscc,
|
postsscc,
|
||||||
pickedup,
|
pickedup,
|
||||||
getShipments,
|
getShipments,
|
||||||
cycleCount,
|
cycleCount,
|
||||||
manualTrigger,
|
manualTrigger,
|
||||||
] as const;
|
] as const;
|
||||||
const setting = await db.select().from(settings);
|
|
||||||
|
|
||||||
const isActive = setting.filter((n) => n.name === "ocmeService");
|
|
||||||
const appRoutes = routes.forEach((route) => {
|
const appRoutes = routes.forEach((route) => {
|
||||||
app.route("/api/v1", route);
|
app.route("/api/v1", route);
|
||||||
});
|
});
|
||||||
|
|
||||||
app.all("/api/v1/*", (c) => {
|
app.all("/api/v1/*", (c) => {
|
||||||
return c.json({
|
return c.json({
|
||||||
success: false,
|
success: false,
|
||||||
message: "you have encounted an ocme route that dose not exist.",
|
message: "you have encounted an ocme route that dose not exist.",
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
if (port && isActive[0]?.value === "1") {
|
|
||||||
serve(
|
|
||||||
{
|
|
||||||
fetch: app.fetch,
|
|
||||||
port: Number(port),
|
|
||||||
hostname: "0.0.0.0",
|
|
||||||
},
|
|
||||||
(info) => {
|
|
||||||
createLog(
|
|
||||||
"info",
|
|
||||||
"LST",
|
|
||||||
"server",
|
|
||||||
`Ocme section is listening on http://${info.address}:${info.port}`
|
|
||||||
);
|
|
||||||
}
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
export default app;
|
export default app;
|
||||||
|
|||||||
@@ -12,7 +12,7 @@
|
|||||||
"contactEmail": "noreply@alpla.com",
|
"contactEmail": "noreply@alpla.com",
|
||||||
"contactPhone": "770-914-1407",
|
"contactPhone": "770-914-1407",
|
||||||
"customerTiAcc": "ALPLA01INTGROUP",
|
"customerTiAcc": "ALPLA01INTGROUP",
|
||||||
"lstServerPort": "4000",
|
"lstServerPort": "3000",
|
||||||
"active": true,
|
"active": true,
|
||||||
"serverLoc": "E:\\LST\\lstv2",
|
"serverLoc": "E:\\LST\\lstv2",
|
||||||
"oldVersion": "E:\\LST\\lst_backend",
|
"oldVersion": "E:\\LST\\lst_backend",
|
||||||
@@ -32,7 +32,7 @@
|
|||||||
"contactEmail": "blake.matthes@alpla.com",
|
"contactEmail": "blake.matthes@alpla.com",
|
||||||
"contactPhone": "6366970253",
|
"contactPhone": "6366970253",
|
||||||
"customerTiAcc": "ALPL01BETHINT",
|
"customerTiAcc": "ALPL01BETHINT",
|
||||||
"lstServerPort": "4000",
|
"lstServerPort": "3000",
|
||||||
"active": true,
|
"active": true,
|
||||||
"serverLoc": "E:\\LST\\lstv2",
|
"serverLoc": "E:\\LST\\lstv2",
|
||||||
"oldVersion": "E:\\LST\\lst_backend",
|
"oldVersion": "E:\\LST\\lst_backend",
|
||||||
@@ -52,7 +52,7 @@
|
|||||||
"contactEmail": "blake.matthes@alpla.com",
|
"contactEmail": "blake.matthes@alpla.com",
|
||||||
"contactPhone": "6366970253",
|
"contactPhone": "6366970253",
|
||||||
"customerTiAcc": "ALPL01HOUSINT",
|
"customerTiAcc": "ALPL01HOUSINT",
|
||||||
"lstServerPort": "4000",
|
"lstServerPort": "3000",
|
||||||
"active": true,
|
"active": true,
|
||||||
"serverLoc": "E:\\LST\\lstv2",
|
"serverLoc": "E:\\LST\\lstv2",
|
||||||
"oldVersion": "E:\\LST\\lst_backend",
|
"oldVersion": "E:\\LST\\lst_backend",
|
||||||
@@ -72,7 +72,7 @@
|
|||||||
"contactEmail": "ShippingReceivingBowlingGreen1@groups.alpla.com",
|
"contactEmail": "ShippingReceivingBowlingGreen1@groups.alpla.com",
|
||||||
"contactPhone": "(270) 495-6647",
|
"contactPhone": "(270) 495-6647",
|
||||||
"customerTiAcc": "ALPL01BG1INT",
|
"customerTiAcc": "ALPL01BG1INT",
|
||||||
"lstServerPort": "4000",
|
"lstServerPort": "3000",
|
||||||
"active": true,
|
"active": true,
|
||||||
"serverLoc": "E:\\LST\\lstv2",
|
"serverLoc": "E:\\LST\\lstv2",
|
||||||
"oldVersion": "E:\\LST\\lst_backend",
|
"oldVersion": "E:\\LST\\lst_backend",
|
||||||
@@ -96,7 +96,7 @@
|
|||||||
"contactEmail": "blake.matthes@alpla.com",
|
"contactEmail": "blake.matthes@alpla.com",
|
||||||
"contactPhone": "6366970253",
|
"contactPhone": "6366970253",
|
||||||
"customerTiAcc": "ALPL01IA2INT",
|
"customerTiAcc": "ALPL01IA2INT",
|
||||||
"lstServerPort": "4001",
|
"lstServerPort": "3001",
|
||||||
"active": true,
|
"active": true,
|
||||||
"serverLoc": "D:\\LST\\lstv2_2",
|
"serverLoc": "D:\\LST\\lstv2_2",
|
||||||
"oldVersion": "D:\\LST\\lst_backend_2",
|
"oldVersion": "D:\\LST\\lst_backend_2",
|
||||||
@@ -116,7 +116,7 @@
|
|||||||
"contactEmail": "blake.matthes@alpla.com",
|
"contactEmail": "blake.matthes@alpla.com",
|
||||||
"contactPhone": "6366970253",
|
"contactPhone": "6366970253",
|
||||||
"customerTiAcc": "ALPL01KCINT",
|
"customerTiAcc": "ALPL01KCINT",
|
||||||
"lstServerPort": "4000",
|
"lstServerPort": "3000",
|
||||||
"active": true,
|
"active": true,
|
||||||
"serverLoc": "E:\\LST\\lstv2",
|
"serverLoc": "E:\\LST\\lstv2",
|
||||||
"oldVersion": "E:\\LST\\lst_backend",
|
"oldVersion": "E:\\LST\\lst_backend",
|
||||||
@@ -136,7 +136,7 @@
|
|||||||
"contactEmail": "blake.matthes@alpla.com",
|
"contactEmail": "blake.matthes@alpla.com",
|
||||||
"contactPhone": "6366970253",
|
"contactPhone": "6366970253",
|
||||||
"customerTiAcc": "ALPL01BG2INT",
|
"customerTiAcc": "ALPL01BG2INT",
|
||||||
"lstServerPort": "4000",
|
"lstServerPort": "3000",
|
||||||
"active": true,
|
"active": true,
|
||||||
"serverLoc": "E:\\LST\\lstv2",
|
"serverLoc": "E:\\LST\\lstv2",
|
||||||
"oldVersion": "E:\\LST\\lst_backend",
|
"oldVersion": "E:\\LST\\lst_backend",
|
||||||
@@ -156,7 +156,7 @@
|
|||||||
"contactEmail": "blake.matthes@alpla.com",
|
"contactEmail": "blake.matthes@alpla.com",
|
||||||
"contactPhone": "6366970253",
|
"contactPhone": "6366970253",
|
||||||
"customerTiAcc": "ALPL01MCDINT",
|
"customerTiAcc": "ALPL01MCDINT",
|
||||||
"lstServerPort": "4000",
|
"lstServerPort": "3000",
|
||||||
"active": true,
|
"active": true,
|
||||||
"serverLoc": "E:\\LST\\lstv2",
|
"serverLoc": "E:\\LST\\lstv2",
|
||||||
"oldVersion": "E:\\LST\\lst_backend",
|
"oldVersion": "E:\\LST\\lst_backend",
|
||||||
@@ -176,7 +176,7 @@
|
|||||||
"contactEmail": "blake.matthes@alpla.com",
|
"contactEmail": "blake.matthes@alpla.com",
|
||||||
"contactPhone": "6366970253",
|
"contactPhone": "6366970253",
|
||||||
"customerTiAcc": "ALPL01DAYTONINT",
|
"customerTiAcc": "ALPL01DAYTONINT",
|
||||||
"lstServerPort": "4000",
|
"lstServerPort": "3000",
|
||||||
"active": true,
|
"active": true,
|
||||||
"serverLoc": "E:\\LST\\lstv2",
|
"serverLoc": "E:\\LST\\lstv2",
|
||||||
"oldVersion": "E:\\LST\\lst_backend",
|
"oldVersion": "E:\\LST\\lst_backend",
|
||||||
@@ -196,7 +196,7 @@
|
|||||||
"contactEmail": "ShippingReceivingSaltLake@groups.alpla.com",
|
"contactEmail": "ShippingReceivingSaltLake@groups.alpla.com",
|
||||||
"contactPhone": "801-673-2143",
|
"contactPhone": "801-673-2143",
|
||||||
"customerTiAcc": "ALPL01SLCINT",
|
"customerTiAcc": "ALPL01SLCINT",
|
||||||
"lstServerPort": "4000",
|
"lstServerPort": "3000",
|
||||||
"active": true,
|
"active": true,
|
||||||
"serverLoc": "E:\\LST\\lstv2",
|
"serverLoc": "E:\\LST\\lstv2",
|
||||||
"oldVersion": "E:\\LST\\lst_backend",
|
"oldVersion": "E:\\LST\\lst_backend",
|
||||||
@@ -216,7 +216,7 @@
|
|||||||
"contactEmail": "blake.matthes@alpla.com",
|
"contactEmail": "blake.matthes@alpla.com",
|
||||||
"contactPhone": "6366970253",
|
"contactPhone": "6366970253",
|
||||||
"customerTiAcc": "ALPL01LIMAINT",
|
"customerTiAcc": "ALPL01LIMAINT",
|
||||||
"lstServerPort": "4000",
|
"lstServerPort": "3000",
|
||||||
"active": true,
|
"active": true,
|
||||||
"serverLoc": "E:\\LST\\lstv2",
|
"serverLoc": "E:\\LST\\lstv2",
|
||||||
"oldVersion": "E:\\LST\\lst_backend",
|
"oldVersion": "E:\\LST\\lst_backend",
|
||||||
@@ -236,7 +236,7 @@
|
|||||||
"contactEmail": "blake.matthes@alpla.com",
|
"contactEmail": "blake.matthes@alpla.com",
|
||||||
"contactPhone": "6366970253",
|
"contactPhone": "6366970253",
|
||||||
"customerTiAcc": "ALPL01FLORINT",
|
"customerTiAcc": "ALPL01FLORINT",
|
||||||
"lstServerPort": "4000",
|
"lstServerPort": "3000",
|
||||||
"active": true,
|
"active": true,
|
||||||
"serverLoc": "E:\\LST\\lstv2",
|
"serverLoc": "E:\\LST\\lstv2",
|
||||||
"oldVersion": "E:\\LST\\lst_backend",
|
"oldVersion": "E:\\LST\\lst_backend",
|
||||||
@@ -256,7 +256,7 @@
|
|||||||
"contactEmail": "blake.matthes@alpla.com",
|
"contactEmail": "blake.matthes@alpla.com",
|
||||||
"contactPhone": "6366970253",
|
"contactPhone": "6366970253",
|
||||||
"customerTiAcc": "ALPL01IA1INT",
|
"customerTiAcc": "ALPL01IA1INT",
|
||||||
"lstServerPort": "4000",
|
"lstServerPort": "3000",
|
||||||
"active": true,
|
"active": true,
|
||||||
"serverLoc": "D:\\LST\\lstv2",
|
"serverLoc": "D:\\LST\\lstv2",
|
||||||
"oldVersion": "D:\\LST\\lst_backend",
|
"oldVersion": "D:\\LST\\lst_backend",
|
||||||
@@ -276,7 +276,7 @@
|
|||||||
"contactEmail": "blake.matthes@alpla.com",
|
"contactEmail": "blake.matthes@alpla.com",
|
||||||
"contactPhone": "6366970253",
|
"contactPhone": "6366970253",
|
||||||
"customerTiAcc": "ALPL01JCINT",
|
"customerTiAcc": "ALPL01JCINT",
|
||||||
"lstServerPort": "4000",
|
"lstServerPort": "3000",
|
||||||
"active": true,
|
"active": true,
|
||||||
"serverLoc": "E:\\LST\\lstv2",
|
"serverLoc": "E:\\LST\\lstv2",
|
||||||
"oldVersion": "E:\\LST\\lst_backend",
|
"oldVersion": "E:\\LST\\lst_backend",
|
||||||
@@ -290,13 +290,13 @@
|
|||||||
"plantToken": "usshe1",
|
"plantToken": "usshe1",
|
||||||
"idAddress": "10.205.0.26",
|
"idAddress": "10.205.0.26",
|
||||||
"greatPlainsPlantCode": "21",
|
"greatPlainsPlantCode": "21",
|
||||||
"streetAddress": "4000 Howe Dr",
|
"streetAddress": "3000 Howe Dr",
|
||||||
"cityState": "Sherman, TX",
|
"cityState": "Sherman, TX",
|
||||||
"zipcode": "75092",
|
"zipcode": "75092",
|
||||||
"contactEmail": "blake.matthes@alpla.com",
|
"contactEmail": "blake.matthes@alpla.com",
|
||||||
"contactPhone": "6366970253",
|
"contactPhone": "6366970253",
|
||||||
"customerTiAcc": "ALPL01SHERMANINT",
|
"customerTiAcc": "ALPL01SHERMANINT",
|
||||||
"lstServerPort": "4000",
|
"lstServerPort": "3000",
|
||||||
"active": true,
|
"active": true,
|
||||||
"serverLoc": "E:\\LST\\lstv2",
|
"serverLoc": "E:\\LST\\lstv2",
|
||||||
"oldVersion": "E:\\LST\\lst_backend",
|
"oldVersion": "E:\\LST\\lst_backend",
|
||||||
@@ -316,7 +316,7 @@
|
|||||||
"contactEmail": "shippingreceivingwestbend@groups.alpla.com",
|
"contactEmail": "shippingreceivingwestbend@groups.alpla.com",
|
||||||
"contactPhone": "262-808-4211",
|
"contactPhone": "262-808-4211",
|
||||||
"customerTiAcc": "ALPL01WBINT",
|
"customerTiAcc": "ALPL01WBINT",
|
||||||
"lstServerPort": "4000",
|
"lstServerPort": "3000",
|
||||||
"active": true,
|
"active": true,
|
||||||
"serverLoc": "E:\\LST\\lstv2",
|
"serverLoc": "E:\\LST\\lstv2",
|
||||||
"oldVersion": "E:\\LST\\lst_backend",
|
"oldVersion": "E:\\LST\\lst_backend",
|
||||||
@@ -341,7 +341,7 @@
|
|||||||
"contactEmail": "blake.matthes@alpla.com",
|
"contactEmail": "blake.matthes@alpla.com",
|
||||||
"contactPhone": "6366970253",
|
"contactPhone": "6366970253",
|
||||||
"customerTiAcc": "ALPL01STPINT",
|
"customerTiAcc": "ALPL01STPINT",
|
||||||
"lstServerPort": "4000",
|
"lstServerPort": "3000",
|
||||||
"active": true,
|
"active": true,
|
||||||
"serverLoc": "E:\\LST\\lstv2",
|
"serverLoc": "E:\\LST\\lstv2",
|
||||||
"oldVersion": "E:\\LST\\lst_backend",
|
"oldVersion": "E:\\LST\\lst_backend",
|
||||||
|
|||||||
@@ -46,6 +46,7 @@ export const serversCheckPoint = async () => {
|
|||||||
shippingHours: servers[i].shippingHours,
|
shippingHours: servers[i].shippingHours,
|
||||||
customerTiAcc: servers[i].customerTiAcc,
|
customerTiAcc: servers[i].customerTiAcc,
|
||||||
serverLoc: servers[i].serverLoc,
|
serverLoc: servers[i].serverLoc,
|
||||||
|
lstServerPort: servers[i].lstServerPort,
|
||||||
oldVersion: servers[i].oldVersion,
|
oldVersion: servers[i].oldVersion,
|
||||||
tiPostTime: servers[i].tiPostTime,
|
tiPostTime: servers[i].tiPostTime,
|
||||||
otherSettings: servers[i].otherSettings,
|
otherSettings: servers[i].otherSettings,
|
||||||
|
|||||||
@@ -19,10 +19,10 @@ const newSubModules = [
|
|||||||
subSubModule: [],
|
subSubModule: [],
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "Bulk orders",
|
name: "Demand Management",
|
||||||
moduleName: "logistics",
|
moduleName: "logistics",
|
||||||
description: "",
|
description: "Bulk order and Forecast imports",
|
||||||
link: "#",
|
link: "/dm",
|
||||||
icon: "Truck",
|
icon: "Truck",
|
||||||
role: ["systemAdmin"],
|
role: ["systemAdmin"],
|
||||||
active: false,
|
active: false,
|
||||||
|
|||||||
Reference in New Issue
Block a user