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); }