User.init({
id: {
type: Sequelize.STRING,
primaryKey: true,
autoIncrement: true
},
nickname: Sequelize.STRING,
email: Sequelize.STRING,
password: Sequelize.STRING,
openid: {
type: Sequelize.STRING,
unique: Sequelize.STRING
}
}, {
sequelize
})
//记得加入 { sequelize }