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.
|
|
|
/* eslint-disable*/
|
|
|
|
'use strict';
|
|
|
|
|
|
|
|
module.exports = dc => {
|
|
|
|
const DataTypes = dc.ORM;
|
|
|
|
const sequelize = dc.orm;
|
|
|
|
const MirrorCamera = sequelize.define("mirrorCamera", {
|
|
|
|
id: {
|
|
|
|
type: DataTypes.INTEGER,
|
|
|
|
allowNull: false,
|
|
|
|
defaultValue: null,
|
|
|
|
comment: null,
|
|
|
|
primaryKey: true,
|
|
|
|
field: "id",
|
|
|
|
autoIncrement: true,
|
|
|
|
unique: "mirror_camera_id_uindex"
|
|
|
|
},
|
|
|
|
cameraId: {
|
|
|
|
type: DataTypes.INTEGER,
|
|
|
|
allowNull: false,
|
|
|
|
defaultValue: null,
|
|
|
|
comment: null,
|
|
|
|
primaryKey: false,
|
|
|
|
field: "camera_id",
|
|
|
|
autoIncrement: false,
|
|
|
|
references: {
|
|
|
|
key: "id",
|
|
|
|
model: "camera"
|
|
|
|
}
|
|
|
|
},
|
|
|
|
treeIds: {
|
|
|
|
type: DataTypes.ARRAY(DataTypes.INTEGER),
|
|
|
|
allowNull: false,
|
|
|
|
defaultValue: null,
|
|
|
|
comment: null,
|
|
|
|
primaryKey: false,
|
|
|
|
field: "tree_ids",
|
|
|
|
autoIncrement: false
|
|
|
|
},
|
|
|
|
filterIds: {
|
|
|
|
type: DataTypes.ARRAY(DataTypes.INTEGER),
|
|
|
|
allowNull: true,
|
|
|
|
defaultValue: null,
|
|
|
|
comment: null,
|
|
|
|
primaryKey: false,
|
|
|
|
field: "filter_ids",
|
|
|
|
autoIncrement: false
|
|
|
|
},
|
|
|
|
mirrorId: {
|
|
|
|
type: DataTypes.INTEGER,
|
|
|
|
allowNull: false,
|
|
|
|
defaultValue: null,
|
|
|
|
comment: null,
|
|
|
|
primaryKey: false,
|
|
|
|
field: "mirror_id",
|
|
|
|
autoIncrement: false,
|
|
|
|
references: {
|
|
|
|
key: "id",
|
|
|
|
model: "mirror"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}, {
|
|
|
|
tableName: "mirror_camera",
|
|
|
|
comment: "",
|
|
|
|
indexes: []
|
|
|
|
});
|
|
|
|
dc.models.MirrorCamera = MirrorCamera;
|
|
|
|
return MirrorCamera;
|
|
|
|
};
|