feat: correct the migration files

This commit is contained in:
Ahmed Bouhuolia
2024-06-04 17:42:29 +02:00
parent 84dd0fa86b
commit 909a70e2c5
4 changed files with 19 additions and 0 deletions

View File

@@ -0,0 +1,14 @@
exports.up = function (knex) {
return knex.schema.createTable('documents', (table) => {
table.increments('id').primary();
table.string('key').notNullable();
table.string('mime_type').notNullable();
table.integer('size').unsigned();
table.string('origin_name');
table.timestamps();
});
};
exports.down = function (knex) {
return knex.schema.dropTableIfExists('documents');
};