seepur/database/migrations/1578967442653_child_schema.js

24 lines
438 B
JavaScript
Raw Normal View History

'use strict'
/** @type {import('@adonisjs/lucid/src/Schema')} */
const Schema = use('Schema')
class ChildSchema extends Schema {
2020-03-17 22:16:34 +00:00
up() {
this.create('children', (table) => {
2020-03-17 22:16:34 +00:00
table.increments();
table.string('name');
table.date('dob');
table.string('avatar');
2020-04-12 14:25:42 +00:00
table.string('profile_cover');
2020-03-17 22:16:34 +00:00
table.timestamps();
})
}
2020-03-17 22:16:34 +00:00
down() {
this.drop('children')
}
}
module.exports = ChildSchema