mirror of
https://github.com/20kaushik02/spotify-manager.git
synced 2025-12-06 09:34:07 +00:00
34 lines
737 B
JavaScript
34 lines
737 B
JavaScript
"use strict";
|
|
/** @type {import("sequelize-cli").Migration} */
|
|
module.exports = {
|
|
async up(queryInterface, Sequelize) {
|
|
await queryInterface.createTable("links", {
|
|
id: {
|
|
allowNull: false,
|
|
autoIncrement: true,
|
|
primaryKey: true,
|
|
type: Sequelize.INTEGER
|
|
},
|
|
userID: {
|
|
type: Sequelize.STRING
|
|
},
|
|
from: {
|
|
type: Sequelize.STRING
|
|
},
|
|
to: {
|
|
type: Sequelize.STRING
|
|
},
|
|
createdAt: {
|
|
allowNull: false,
|
|
type: Sequelize.DATE
|
|
},
|
|
updatedAt: {
|
|
allowNull: false,
|
|
type: Sequelize.DATE
|
|
}
|
|
});
|
|
},
|
|
async down(queryInterface, Sequelize) {
|
|
await queryInterface.dropTable("links");
|
|
}
|
|
}; |