Compare commits
6 Commits
20fc286069
...
566754bf2e
| Author | SHA1 | Date | |
|---|---|---|---|
| 566754bf2e | |||
| 50b7c9cac5 | |||
| b0ac326752 | |||
| 9572b71592 | |||
| 96c3e4c24a | |||
| aba1668d2c |
@@ -18,7 +18,7 @@ const registerSchema = z.object({
|
||||
.string()
|
||||
.min(3)
|
||||
.max(32)
|
||||
.regex(/^[a-zA-Z0-9.]+$/, "Only alphanumeric + dots allowed"),
|
||||
.regex(/^[a-zA-Z0-9._]+$/, "Only alphanumeric + dots allowed"),
|
||||
displayUsername: z.string().min(2).max(100).optional(), // optional in your API, but supported
|
||||
});
|
||||
|
||||
|
||||
@@ -8,6 +8,7 @@ import {
|
||||
} from "@tanstack/react-table";
|
||||
import React, { useState } from "react";
|
||||
import { Button } from "@/components/ui/button";
|
||||
import { ScrollArea, ScrollBar } from "@/components/ui/scroll-area";
|
||||
import {
|
||||
Table,
|
||||
TableBody,
|
||||
@@ -32,6 +33,7 @@ export default function TableNoExpand({
|
||||
getPaginationRowModel: getPaginationRowModel(),
|
||||
onSortingChange: setSorting,
|
||||
getSortedRowModel: getSortedRowModel(),
|
||||
|
||||
//renderSubComponent: ({ row }: { row: any }) => <ExpandedRow row={row} />,
|
||||
//getRowCanExpand: () => true,
|
||||
state: {
|
||||
@@ -40,7 +42,7 @@ export default function TableNoExpand({
|
||||
});
|
||||
return (
|
||||
<div className="p-4">
|
||||
<div className="">
|
||||
<ScrollArea className="w-11/12 rounded-md border whitespace-nowrap">
|
||||
<Table>
|
||||
<TableHeader>
|
||||
{table.getHeaderGroups().map((headerGroup) => (
|
||||
@@ -106,7 +108,8 @@ export default function TableNoExpand({
|
||||
Next
|
||||
</Button>
|
||||
</div>
|
||||
</div>
|
||||
<ScrollBar orientation="horizontal" />
|
||||
</ScrollArea>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -55,7 +55,7 @@ export const labelRatioColumns: ColumnDef<Adjustmnets>[] = [
|
||||
const resetReads = async () => {
|
||||
setReaderReset(true);
|
||||
try {
|
||||
const res = await axios.post("/api/ocp/resetlabelratio", {
|
||||
const res = await axios.post("/lst/old/api/ocp/resetlabelratio", {
|
||||
reader: name,
|
||||
});
|
||||
|
||||
|
||||
@@ -30,6 +30,7 @@ type Pallets = {
|
||||
durationToMove: null;
|
||||
qualityDurationToInspect: number;
|
||||
returnDurationToInspect: number;
|
||||
locationMovesTo: string;
|
||||
locationDropOff: string;
|
||||
palletStatus: number;
|
||||
palletStatusText: string;
|
||||
@@ -165,6 +166,26 @@ export default function QualityRequest() {
|
||||
);
|
||||
},
|
||||
}),
|
||||
columnHelper.accessor("locationMovesTo", {
|
||||
header: ({ column }) => {
|
||||
return (
|
||||
<Button
|
||||
variant="ghost"
|
||||
onClick={() => column.toggleSorting(column.getIsSorted() === "asc")}
|
||||
>
|
||||
<span className="flex flex-row gap-2">Location At Request</span>
|
||||
{column.getIsSorted() === "asc" ? (
|
||||
<ArrowUp className="ml-2 h-4 w-4" />
|
||||
) : (
|
||||
<ArrowDown className="ml-2 h-4 w-4" />
|
||||
)}
|
||||
</Button>
|
||||
);
|
||||
},
|
||||
cell: ({ getValue }) => {
|
||||
return <span>{getValue() === "" ? "Pending Move" : getValue()}</span>;
|
||||
},
|
||||
}),
|
||||
columnHelper.accessor("locationDropOff", {
|
||||
header: ({ column }) => {
|
||||
return (
|
||||
|
||||
@@ -45,6 +45,12 @@ export default function RequestPallet() {
|
||||
"You did not change the running number, please add a valid running number",
|
||||
);
|
||||
}
|
||||
|
||||
if (value.moveTo === "") {
|
||||
return toast.error(
|
||||
"Please select where you would like the pallets taken to.",
|
||||
);
|
||||
}
|
||||
const postData = {
|
||||
runningNr: Number(value.runningNr),
|
||||
moveTo: value.moveTo,
|
||||
|
||||
1
lstV2/database/migrations/0077_lucky_texas_twister.sql
Normal file
1
lstV2/database/migrations/0077_lucky_texas_twister.sql
Normal file
@@ -0,0 +1 @@
|
||||
ALTER TABLE "qualityRequest" ADD COLUMN "comments" text;
|
||||
2284
lstV2/database/migrations/meta/0077_snapshot.json
Normal file
2284
lstV2/database/migrations/meta/0077_snapshot.json
Normal file
File diff suppressed because it is too large
Load Diff
@@ -540,6 +540,13 @@
|
||||
"when": 1763134709763,
|
||||
"tag": "0076_stiff_champions",
|
||||
"breakpoints": true
|
||||
},
|
||||
{
|
||||
"idx": 77,
|
||||
"version": "7",
|
||||
"when": 1763407463567,
|
||||
"tag": "0077_lucky_texas_twister",
|
||||
"breakpoints": true
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -36,6 +36,7 @@ export const qualityRequest = pgTable(
|
||||
add_user: text("add_user").default("LST"),
|
||||
upd_date: timestamp("upd_date").defaultNow(),
|
||||
upd_user: text("upd_user").default("LST"),
|
||||
comments: text("comments")
|
||||
},
|
||||
(table) => [
|
||||
// uniqueIndex('emailUniqueIndex').on(sql`lower(${table.email})`),
|
||||
|
||||
Reference in New Issue
Block a user