Skip to content

Instantly share code, notes, and snippets.

@Bomfim
Last active November 2, 2020 04:11
Show Gist options
  • Select an option

  • Save Bomfim/4acbab58253e67a0dbb6d8a40f1939f0 to your computer and use it in GitHub Desktop.

Select an option

Save Bomfim/4acbab58253e67a0dbb6d8a40f1939f0 to your computer and use it in GitHub Desktop.
models/plan.js
const { dbConnection } = require("../config/db");
const { DataTypes } = require("sequelize");
const Plan = dbConnection.define(
"Plan",
{
Id: {
type: DataTypes.INTEGER,
primaryKey: true,
autoIncrement: true,
},
Description: DataTypes.STRING,
LifespanBegin: DataTypes.DATE,
LifespanEnd: DataTypes.DATE,
Version: DataTypes.STRING,
Status: DataTypes.BOOLEAN,
},
{ timestamps: false }
);
module.exports = Plan;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment