summaryrefslogtreecommitdiffstats
path: root/server/migrations/20181008151633-create-registrationhook.js
blob: 0a96f29f15c030334a67b53702ebf601a849bb75 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
'use strict'
module.exports = {
  up: (queryInterface, Sequelize) => {
    return queryInterface.createTable('registrationhooks', {
      id: {
        primaryKey: true,
        autoIncrement: true,
        allowNull: false,
        type: Sequelize.INTEGER
      },
      name: {
        type: Sequelize.STRING
      },
      description: {
        type: Sequelize.STRING(2048)
      },
      sortvalue: Sequelize.INTEGER,
      type: Sequelize.STRING,
      script: {
        allowNull: true,
        type: Sequelize.BLOB
      }
    })
  },
  down: (queryInterface, Sequelize) => {
    return queryInterface.dropTable('registrationhook')
  }
}