20241117173947_user.ts 478 B

123456789101112131415
  1. // For more information about this file see https://dove.feathersjs.com/guides/cli/knexfile.html
  2. import type { Knex } from 'knex'
  3. export async function up(knex: Knex): Promise<void> {
  4. await knex.schema.createTable('users', (table) => {
  5. table.increments('id');
  6. table.string('username').unique();
  7. table.string('email').unique();
  8. table.string('password');
  9. })
  10. }
  11. export async function down(knex: Knex): Promise<void> {
  12. await knex.schema.dropTable('users');
  13. }