spee.ch/models/file.js

40 lines
733 B
JavaScript
Raw Normal View History

module.exports = (sequelize, { STRING, BOOLEAN }) => {
const File = sequelize.define(
'File',
{
name: {
type : STRING,
allowNull: false,
},
2017-06-20 00:25:14 +02:00
claimId: {
type : STRING,
allowNull: false,
},
outpoint: {
type : STRING,
allowNull: false,
},
2017-06-20 00:25:14 +02:00
fileName: {
type : STRING,
allowNull: false,
},
2017-06-20 00:25:14 +02:00
filePath: {
type : STRING,
allowNull: false,
},
2017-06-20 00:25:14 +02:00
fileType: {
type: STRING,
},
nsfw: {
type : BOOLEAN,
allowNull : false,
defaultValue: false,
},
},
{
freezeTableName: true,
}
);
return File;
};