0
當從窗體(req.body)獲取值時,是否必須運行parseInt或者如果值爲空字符串,我可以告訴sequelize將其設置爲0嗎?sequelize parseint INTEGER
使用:
req.body.price_low_day = parseInt(req.body.price_low_day) || 0; // want to get rid of this row.
room.update(req.body) ?