27 lines
462 B
JavaScript
Raw Normal View History

2020-01-20 09:12:01 +01:00
/* eslint-disable no-magic-numbers */
2020-02-20 10:57:22 +01:00
'use strict';
2020-01-20 09:12:01 +01:00
/**
* execute migration
*
* @param {any} knex database connections
*/
async function up (knex) {
await knex.schema.createTable ('template', (table) => {
table.increments ('id');
table.string ('text', 64);
});
}
/**
* revert migration
*
* @param {any} knex database connections
*/
async function down (knex) {
await knex.schema.dropTable ('template');
}
module.exports = { up, down };