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.
52 lines
1.3 KiB
52 lines
1.3 KiB
/* eslint-disable*/
|
|
'use strict';
|
|
|
|
module.exports = dc => {
|
|
const DataTypes = dc.ORM;
|
|
const sequelize = dc.orm;
|
|
const Publicity = sequelize.define("publicity", {
|
|
id: {
|
|
type: DataTypes.INTEGER,
|
|
allowNull: false,
|
|
defaultValue: null,
|
|
comment: null,
|
|
primaryKey: true,
|
|
field: "id",
|
|
autoIncrement: true,
|
|
unique: "publicity_id_uindex"
|
|
},
|
|
name: {
|
|
type: DataTypes.STRING,
|
|
allowNull: false,
|
|
defaultValue: null,
|
|
comment: null,
|
|
primaryKey: false,
|
|
field: "name",
|
|
autoIncrement: false
|
|
},
|
|
video: {
|
|
type: DataTypes.ARRAY(DataTypes.INTEGER),
|
|
allowNull: true,
|
|
defaultValue: null,
|
|
comment: null,
|
|
primaryKey: false,
|
|
field: "video",
|
|
autoIncrement: false
|
|
},
|
|
enable: {
|
|
type: DataTypes.BOOLEAN,
|
|
allowNull: false,
|
|
defaultValue: true,
|
|
comment: null,
|
|
primaryKey: false,
|
|
field: "enable",
|
|
autoIncrement: false
|
|
}
|
|
}, {
|
|
tableName: "publicity",
|
|
comment: "",
|
|
indexes: []
|
|
});
|
|
dc.models.Publicity = Publicity;
|
|
return Publicity;
|
|
};
|