From eacae8835efadd45a1ff5891c4893110369c43b2 Mon Sep 17 00:00:00 2001 From: jusax23 Date: Sat, 1 Apr 2023 11:49:42 +0200 Subject: [PATCH] bigint fix --- src/api/acts/roomContent.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/api/acts/roomContent.ts b/src/api/acts/roomContent.ts index 3f72719..1f8fc06 100644 --- a/src/api/acts/roomContent.ts +++ b/src/api/acts/roomContent.ts @@ -84,7 +84,7 @@ export const addCategory: Act = { .limit(1) ).query(db); if (req.affectedRows > 0) aws("ok", { - catID: req.insertId + catID: Number(req.insertId) }); else aws("error", act_error.ADD_CAT); } @@ -290,7 +290,7 @@ export const addProduct: Act = { data.parent > -1 ? data.parent : null, ).query(db); if (req.affectedRows > 0) aws("ok", { - listProdID: req.insertId + listProdID: Number(req.insertId) }); else aws("error", act_error.ADD_PROD); } @@ -481,7 +481,7 @@ export const addItem: Act = { data.listProdID > -1 ? data.parent : null, ).query(db); if (req.affectedRows > 0) aws("ok", { - listItemID: req.insertId + listItemID: Number(req.insertId) }); else aws("error", act_error.ADD_ITEM); }