fix(dm): correction to passing the username over for the importing of the file
This commit is contained in:
@@ -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);
|
||||
|
||||
@@ -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);
|
||||
|
||||
Reference in New Issue
Block a user