You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
canteen/model/orderModel.js

35 lines
732 B

const sequelize = require("../dbConnect")
const {
DataTypes
} = require("sequelize")
module.exports = sequelize.define("order", {
userId: {
type: DataTypes.INTEGER,
allowNull: false
},
orderDate: {
type: DataTypes.DATEONLY,
allowNull: false
},
dishName: {
type: DataTypes.STRING,
allowNull: false
},
quantity: {
type: DataTypes.INTEGER,
allowNull: false
},
status: {
type: DataTypes.STRING,
allowNull: false
},
totalAmount: {
type: DataTypes.INTEGER,
allowNull: false
},
}, {
freezeTableName: true,
createdAt: false,
updatedAt: false,
})