12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152 |
- /* indent size: 2 */
- // eslint-disable-next-line strict
- module.exports = app => {
- const DataTypes = app.Sequelize;
- const Model = app.model.define('UsersEventLogs', {
- id: {
- type: DataTypes.INTEGER(10).UNSIGNED,
- allowNull: false,
- primaryKey: true,
- autoIncrement: true,
- },
- user_id: {
- type: DataTypes.INTEGER(10).UNSIGNED,
- allowNull: true,
- },
- event_count: {
- type: DataTypes.INTEGER(10),
- allowNull: true,
- },
- event_name: {
- type: DataTypes.STRING(255),
- allowNull: true,
- },
- event_params: {
- type: DataTypes.STRING(255),
- allowNull: true,
- },
- update_time: {
- type: DataTypes.TIME,
- allowNull: true,
- },
- create_time: {
- type: DataTypes.DATE,
- allowNull: true,
- },
- pid: {
- type: DataTypes.INTEGER(4).UNSIGNED,
- allowNull: true,
- },
- }, {
- tableName: 'szj_users_event_logs',
- });
- Model.associate = function() {
- };
- // 同步:没有就新建,有就不变
- Model.sync();
- return Model;
- };
|