fix(manual print): fixed so the print disables

This commit is contained in:
2025-10-30 14:20:30 -05:00
parent 2a83f92850
commit d3e8e94110

View File

@@ -18,6 +18,7 @@ export default function ManualPrint({ lot }: { lot: LotType }) {
//const serverUrl = `http://${server}:${serverPort}`;
const handlePrintLabel = async (lot: LotType) => {
setPrinting(true);
const labels: any = await manualPrintLabels(lot, session?.user);
if (labels.success) {
@@ -25,7 +26,6 @@ export default function ManualPrint({ lot }: { lot: LotType }) {
setTimeout(() => {
setPrinting(false);
}, 5 * 1000);
setPrinting(true);
} else {
toast.error(labels.message);
setTimeout(() => {