Files
api.personalink/database/migrations/1778591347252_create_social_links_table.js
2026-05-13 11:50:22 +02:00

20 lines
734 B
JavaScript

import { BaseSchema } from '@adonisjs/lucid/schema';
export default class extends BaseSchema {
tableName = 'social_links';
async up() {
this.schema.createTable(this.tableName, (table) => {
table.increments('id');
table.string('platform').notNullable();
table.string('url').notNullable();
table.string('username').notNullable();
table.string('icon').notNullable();
table.string('color').notNullable();
table.timestamp('created_at');
table.timestamp('updated_at');
});
}
async down() {
this.schema.dropTable(this.tableName);
}
}
//# sourceMappingURL=1778591347252_create_social_links_table.js.map