mirror of
https://github.com/ArthurDanjou/artdanj-api.git
synced 2026-01-25 09:10:25 +01:00
19 lines
445 B
TypeScript
19 lines
445 B
TypeScript
import BaseSchema from '@ioc:Adonis/Lucid/Schema'
|
|
|
|
export default class GoldenMessages extends BaseSchema {
|
|
protected tableName = 'golden_messages'
|
|
|
|
public async up () {
|
|
this.schema.createTable(this.tableName, (table) => {
|
|
table.increments('id')
|
|
table.integer('user_id').notNullable()
|
|
table.string('message')
|
|
table.timestamps()
|
|
})
|
|
}
|
|
|
|
public async down () {
|
|
this.schema.dropTable(this.tableName)
|
|
}
|
|
}
|