chore: Unify backend express project into ESM (#281)
This commit is contained in:
@@ -1,26 +1,21 @@
|
||||
'use strict';
|
||||
export async function up(queryInterface) {
|
||||
/**
|
||||
* Add altering commands here.
|
||||
*
|
||||
* Example:
|
||||
* await queryInterface.createTable('users', { id: Sequelize.INTEGER });
|
||||
*/
|
||||
|
||||
/** @type {import('sequelize-cli').Migration} */
|
||||
module.exports = {
|
||||
async up(queryInterface) {
|
||||
/**
|
||||
* Add altering commands here.
|
||||
*
|
||||
* Example:
|
||||
* await queryInterface.createTable('users', { id: Sequelize.INTEGER });
|
||||
*/
|
||||
await queryInterface.renameColumn('users', 'createdAt', 'created_at');
|
||||
await queryInterface.renameColumn('users', 'updatedAt', 'updated_at');
|
||||
await queryInterface.renameColumn('users', 'avatarPath', 'avatar_path');
|
||||
}
|
||||
|
||||
await queryInterface.renameColumn('users', 'createdAt', 'created_at');
|
||||
await queryInterface.renameColumn('users', 'updatedAt', 'updated_at');
|
||||
await queryInterface.renameColumn('users', 'avatarPath', 'avatar_path');
|
||||
},
|
||||
|
||||
async down() {
|
||||
/**
|
||||
* Add reverting commands here.
|
||||
*
|
||||
* Example:
|
||||
* await queryInterface.dropTable('users');
|
||||
*/
|
||||
},
|
||||
};
|
||||
export async function down() {
|
||||
/**
|
||||
* Add reverting commands here.
|
||||
*
|
||||
* Example:
|
||||
* await queryInterface.dropTable('users');
|
||||
*/
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user