mirror of
https://github.com/rgrgogu/new_starr.git
synced 2026-09-27 00:12:54 +08:00
ready to test
Testing Signed-off-by: Kenneth Obsequio <k80308392@gmail.com>
This commit is contained in:
@@ -0,0 +1,22 @@
|
||||
'use strict';
|
||||
|
||||
module.exports = {
|
||||
async up(queryInterface, Sequelize) {
|
||||
await queryInterface.createTable('tier_plans', {
|
||||
plan_id: { type: Sequelize.BIGINT, primaryKey: true, autoIncrement: true },
|
||||
tier: { type: Sequelize.ENUM('premium', 'exclusive'), allowNull: false },
|
||||
label: { type: Sequelize.STRING(100), allowNull: false },
|
||||
duration_days: { type: Sequelize.INTEGER, allowNull: false },
|
||||
price: { type: Sequelize.DECIMAL(10, 2), allowNull: false },
|
||||
currency: { type: Sequelize.CHAR(3), allowNull: false, defaultValue: 'USD' },
|
||||
is_active: { type: Sequelize.BOOLEAN, allowNull: false, defaultValue: true },
|
||||
createdAt: { type: Sequelize.DATE, allowNull: false },
|
||||
updatedAt: { type: Sequelize.DATE, allowNull: false },
|
||||
deletedAt: { type: Sequelize.DATE, allowNull: true },
|
||||
});
|
||||
},
|
||||
|
||||
async down(queryInterface) {
|
||||
await queryInterface.dropTable('tier_plans');
|
||||
},
|
||||
};
|
||||
Reference in New Issue
Block a user