feat(api): add initial schema migration
This commit is contained in:
11
backend/migrations/20260220000001_initial_schema.js
Normal file
11
backend/migrations/20260220000001_initial_schema.js
Normal file
@@ -0,0 +1,11 @@
|
||||
export async function up(knex) {
|
||||
await knex.schema.createTable('cv_data', (table) => {
|
||||
table.integer('id').primary();
|
||||
table.text('data').notNullable();
|
||||
table.datetime('updated_at').defaultTo(knex.fn.now());
|
||||
});
|
||||
}
|
||||
|
||||
export async function down(knex) {
|
||||
await knex.schema.dropTableIfExists('cv_data');
|
||||
}
|
||||
Reference in New Issue
Block a user