spotify-manager/migrations/20240730101615-create-links.js
Kaushik Narayan R d999db53ae back
small improvements, bug fixes, ocd formatting,
2024-12-26 03:13:35 -07:00

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");
}
};