Initial commit
TODO: change api.conf URL references to use environment variables and add these variables to the docker-compose configuration for host domain
This commit is contained in:
32
api/db/models/Course.model.js
Normal file
32
api/db/models/Course.model.js
Normal file
@@ -0,0 +1,32 @@
|
||||
const Sequelize = require("sequelize");
|
||||
|
||||
module.exports = {
|
||||
name: {
|
||||
type: Sequelize.DataTypes.STRING(100),
|
||||
allowNull: false
|
||||
},
|
||||
shortName: {
|
||||
type: Sequelize.DataTypes.STRING(70),
|
||||
allowNull: false
|
||||
},
|
||||
category: {
|
||||
type: Sequelize.DataTypes.STRING(100),
|
||||
allowNull: false
|
||||
},
|
||||
description: {
|
||||
type: Sequelize.DataTypes.STRING(1000),
|
||||
allowNull: true
|
||||
},
|
||||
imageUrl: {
|
||||
type: Sequelize.DataTypes.STRING,
|
||||
allowNull: true
|
||||
},
|
||||
createdById: {
|
||||
type: Sequelize.DataTypes.INTEGER,
|
||||
allowNull: false,
|
||||
},
|
||||
lastModifiedById: {
|
||||
type: Sequelize.DataTypes.INTEGER,
|
||||
allowNull: false,
|
||||
},
|
||||
};
|
||||
Reference in New Issue
Block a user