@devx-commerce/plugin-gati
Version:
Gati ERP integration for Medusa
18 lines • 4.5 kB
JavaScript
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.Migration20250601045242 = void 0;
const migrations_1 = require("@mikro-orm/migrations");
class Migration20250601045242 extends migrations_1.Migration {
async up() {
this.addSql(`alter table if exists "extended_variant" add column if not exists "grp_group_no" integer not null, add column if not exists "category_group_name" text not null, add column if not exists "category_group_code" text not null, add column if not exists "grp_no" integer not null, add column if not exists "category_code" text not null, add column if not exists "sub_itm_no" integer not null, add column if not exists "sub_category_code" text not null, add column if not exists "make_type_no" integer not null, add column if not exists "make_type_code" text not null, add column if not exists "stock_type_no" integer not null, add column if not exists "stock_type_code" text not null, add column if not exists "item_size_id" integer not null, add column if not exists "item_size_name" text not null, add column if not exists "brand_no" integer not null, add column if not exists "brand_name" text not null, add column if not exists "gender_no" integer not null, add column if not exists "gender_name" text not null;`);
this.addSql(`alter table if exists "party_style_details_line" add column if not exists "item_id" integer not null, add column if not exists "item_name" text not null, add column if not exists "raw_no" integer not null, add column if not exists "shape_no" integer not null, add column if not exists "qly_no" integer not null, add column if not exists "tone_no" integer not null, add column if not exists "size_no" integer not null, add column if not exists "size_name" text not null, add column if not exists "accessories_id" integer not null, add column if not exists "accessories_name" text not null, add column if not exists "smd_set_no" integer not null, add column if not exists "setting_name" text not null;`);
this.addSql(`alter table if exists "party_style_exploration_line" add column if not exists "exploration_id" integer not null, add column if not exists "exploration_name" text not null;`);
}
async down() {
this.addSql(`alter table if exists "extended_variant" drop column if exists "grp_group_no", drop column if exists "category_group_name", drop column if exists "category_group_code", drop column if exists "grp_no", drop column if exists "category_code", drop column if exists "sub_itm_no", drop column if exists "sub_category_code", drop column if exists "make_type_no", drop column if exists "make_type_code", drop column if exists "stock_type_no", drop column if exists "stock_type_code", drop column if exists "item_size_id", drop column if exists "item_size_name", drop column if exists "brand_no", drop column if exists "brand_name", drop column if exists "gender_no", drop column if exists "gender_name";`);
this.addSql(`alter table if exists "party_style_details_line" drop column if exists "item_id", drop column if exists "item_name", drop column if exists "raw_no", drop column if exists "shape_no", drop column if exists "qly_no", drop column if exists "tone_no", drop column if exists "size_no", drop column if exists "size_name", drop column if exists "accessories_id", drop column if exists "accessories_name", drop column if exists "smd_set_no", drop column if exists "setting_name";`);
this.addSql(`alter table if exists "party_style_exploration_line" drop column if exists "exploration_id", drop column if exists "exploration_name";`);
}
}
exports.Migration20250601045242 = Migration20250601045242;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiTWlncmF0aW9uMjAyNTA2MDEwNDUyNDIuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9zcmMvbW9kdWxlcy9leHRlbmRlZC12YXJpYW50L21pZ3JhdGlvbnMvTWlncmF0aW9uMjAyNTA2MDEwNDUyNDIudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7O0FBQUEsc0RBQWtEO0FBRWxELE1BQWEsdUJBQXdCLFNBQVEsc0JBQVM7SUFFM0MsS0FBSyxDQUFDLEVBQUU7UUFDZixJQUFJLENBQUMsTUFBTSxDQUFDLG0vQkFBbS9CLENBQUMsQ0FBQztRQUVqZ0MsSUFBSSxDQUFDLE1BQU0sQ0FBQyw2ckJBQTZyQixDQUFDLENBQUM7UUFFM3NCLElBQUksQ0FBQyxNQUFNLENBQUMsNktBQTZLLENBQUMsQ0FBQztJQUM3TCxDQUFDO0lBRVEsS0FBSyxDQUFDLElBQUk7UUFDakIsSUFBSSxDQUFDLE1BQU0sQ0FBQywwckJBQTByQixDQUFDLENBQUM7UUFFeHNCLElBQUksQ0FBQyxNQUFNLENBQUMseWRBQXlkLENBQUMsQ0FBQztRQUV2ZSxJQUFJLENBQUMsTUFBTSxDQUFDLHdJQUF3SSxDQUFDLENBQUM7SUFDeEosQ0FBQztDQUVGO0FBbEJELDBEQWtCQyJ9