26 lines
496 B
JavaScript
26 lines
496 B
JavaScript
"use strict";
|
|
const {
|
|
Model
|
|
} = require("sequelize");
|
|
module.exports = (sequelize, DataTypes) => {
|
|
class SandwichOrder extends Model {
|
|
static associate(models) {
|
|
}
|
|
}
|
|
SandwichOrder.init({
|
|
id: {
|
|
type: DataTypes.INTEGER,
|
|
primaryKey: true,
|
|
autoIncrement: true
|
|
},
|
|
date: {
|
|
type: DataTypes.DATEONLY,
|
|
defaultValue: DataTypes.NOW,
|
|
allowNull: false
|
|
}
|
|
}, {
|
|
sequelize,
|
|
modelName: "SandwichOrder",
|
|
});
|
|
return SandwichOrder;
|
|
};
|