1
0
Fork 0
mirror of https://github.com/pawelmalak/flame.git synced 2025-07-19 19:49:37 +02:00

Config model and controllers

This commit is contained in:
unknown 2021-05-15 18:33:59 +02:00
parent 873faa6c97
commit 3fc3d07598
5 changed files with 144 additions and 1 deletions

26
models/Config.js Normal file
View file

@ -0,0 +1,26 @@
const { DataTypes } = require('sequelize');
const { sequelize } = require('../db');
const Config = sequelize.define('Config', {
key: {
type: DataTypes.STRING,
allowNull: false,
unique: true
},
value: {
type: DataTypes.STRING,
allowNull: false
},
valueType: {
type: DataTypes.STRING,
allowNull: false
},
isLocked: {
type: DataTypes.BOOLEAN,
defaultValue: false
}
}, {
freezeTableName: true
});
module.exports = Config;