政务数据资源中心(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.
 
 
 
 

81 lines
1.7 KiB

/* eslint-disable*/
'use strict';
module.exports = dc => {
const DataTypes = dc.ORM;
const sequelize = dc.orm;
const User = sequelize.define("user", {
id: {
type: DataTypes.INTEGER,
allowNull: false,
defaultValue: null,
comment: "唯一标识",
primaryKey: true,
field: "id",
autoIncrement: true,
unique: "t_user_id_uindex"
},
name: {
type: DataTypes.STRING,
allowNull: true,
defaultValue: null,
comment: "姓名",
primaryKey: false,
field: "name",
autoIncrement: false
},
username: {
type: DataTypes.STRING,
allowNull: false,
defaultValue: null,
comment: "用户名",
primaryKey: false,
field: "username",
autoIncrement: false
},
password: {
type: DataTypes.STRING,
allowNull: false,
defaultValue: null,
comment: "密码",
primaryKey: false,
field: "password",
autoIncrement: false
},
role: {
type: DataTypes.STRING,
allowNull: false,
defaultValue: null,
comment: "角色",
primaryKey: false,
field: "role",
autoIncrement: false
},
enabled: {
type: DataTypes.BOOLEAN,
allowNull: true,
defaultValue: true,
comment: "是否启用",
primaryKey: false,
field: "enabled",
autoIncrement: false
},
orgId: {
type: DataTypes.INTEGER,
allowNull: true,
defaultValue: null,
comment: null,
primaryKey: false,
field: "orgId",
autoIncrement: false
}
}, {
tableName: "t_user",
comment: "",
indexes: []
});
dc.models.User = User;
return User;
};