22 lines
510 B
JavaScript
22 lines
510 B
JavaScript
|
|
'use strict';
|
||
|
|
|
||
|
|
module.exports = (app) => {
|
||
|
|
const { INTEGER, CHAR, STRING, DATE } = app.Sequelize;
|
||
|
|
|
||
|
|
const BNtripRecord = app.model.define('bntrip-record', {
|
||
|
|
id: { type: INTEGER(8), primaryKey: true, autoIncrement: true },
|
||
|
|
user_uid: CHAR(15),
|
||
|
|
organization: CHAR(15),
|
||
|
|
mountpoint: STRING(100),
|
||
|
|
befor_edit: STRING(100),
|
||
|
|
created_at: DATE,
|
||
|
|
updated_at: DATE
|
||
|
|
}, {
|
||
|
|
freezeTableName: true,
|
||
|
|
timestamp: true,
|
||
|
|
createdAt: true,
|
||
|
|
updatedAt: true
|
||
|
|
});
|
||
|
|
|
||
|
|
return BNtripRecord;
|
||
|
|
};
|