fix(dm): correction to passing the username over for the importing of the file

This commit is contained in:
2025-10-31 09:41:08 -05:00
parent 1283a63b5f
commit a7a9aa2874
7 changed files with 50 additions and 12 deletions

View File

@@ -36,15 +36,13 @@ app.openapi(
async (c) => {
apiHit(c, { endpoint: "/postbulkorders" });
const body = await c.req.parseBody();
//console.log(body); // File | string
//console.log(body.username); // File | string
// if (body["fileType"] === "standard") {
// console.log(`doing standard orders in.`);
// }
const { data: orders, error } = await tryCatch(
ordersIn(body, c.get("user")),
);
const { data: orders, error } = await tryCatch(ordersIn(body, body));
if (error) {
console.log(error);

View File

@@ -44,9 +44,7 @@ app.openapi(
// console.log(`doing standard orders in.`);
// }
const { data: orders, error } = await tryCatch(
forecastIn(body, c.get("user")),
);
const { data: orders, error } = await tryCatch(forecastIn(body, body));
if (error) {
console.log(error);