政务数据资源中心(Government data Resource center) 03专项3期主要建设内容
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.
 
 
 
 

133 lines
3.6 KiB

/* eslint-disable*/
'use strict';
module.exports = dc => {
const DataTypes = dc.ORM;
const sequelize = dc.orm;
const MetadataFile = sequelize.define("metadataFile", {
id: {
type: DataTypes.INTEGER,
allowNull: false,
defaultValue: null,
comment: "唯一标识",
primaryKey: true,
field: "id",
autoIncrement: true,
unique: "t_metadata_file_id_uindex"
},
name: {
type: DataTypes.STRING,
allowNull: false,
defaultValue: null,
comment: "文件名称",
primaryKey: false,
field: "name",
autoIncrement: false
},
type: {
type: DataTypes.STRING,
allowNull: false,
defaultValue: null,
comment: "文件类型",
primaryKey: false,
field: "type",
autoIncrement: false
},
size: {
type: DataTypes.INTEGER,
allowNull: false,
defaultValue: null,
comment: "文件大小",
primaryKey: false,
field: "size",
autoIncrement: false
},
description: {
type: DataTypes.STRING,
allowNull: true,
defaultValue: null,
comment: "文件描述",
primaryKey: false,
field: "description",
autoIncrement: false
},
attributesParam: {
type: DataTypes.JSONB,
allowNull: true,
defaultValue: null,
comment: "属性",
primaryKey: false,
field: "attributes",
autoIncrement: false
},
catalog: {
type: DataTypes.INTEGER,
allowNull: false,
defaultValue: null,
comment: "资源目录",
primaryKey: false,
field: "catalog",
autoIncrement: false,
references: {
key: "id",
model: "tResourceCatalog"
}
},
createBy: {
type: DataTypes.INTEGER,
allowNull: false,
defaultValue: null,
comment: "创建者",
primaryKey: false,
field: "create_by",
autoIncrement: false,
references: {
key: "id",
model: "tUser"
}
},
createAt: {
type: DataTypes.DATE,
allowNull: false,
defaultValue: null,
comment: "创建时间",
primaryKey: false,
field: "create_at",
autoIncrement: false
},
updateAt: {
type: DataTypes.DATE,
allowNull: true,
defaultValue: null,
comment: "修改时间",
primaryKey: false,
field: "update_at",
autoIncrement: false
},
catalogKey: {
type: DataTypes.STRING,
allowNull: false,
defaultValue: null,
comment: null,
primaryKey: false,
field: "catalogKey",
autoIncrement: false
},
fileName: {
type: DataTypes.STRING,
allowNull: false,
defaultValue: null,
comment: null,
primaryKey: false,
field: "file_name",
autoIncrement: false
}
}, {
tableName: "t_metadata_file",
comment: "",
indexes: []
});
dc.models.MetadataFile = MetadataFile;
return MetadataFile;
};