1 import { Migration } from "@medusajs/framework/mikro-orm/migrations"
2
3 export class Migration20240902195921 extends Migration {
4 async up(): Promise<void> {
5 this.addSql(
6 'alter table if exists "order_line_item" add column if not exists "is_custom_price" boolean not null default false;'
7 )
8
9 this.addSql(
10 'alter table if exists "order_shipping_method" add column if not exists "is_custom_amount" boolean not null default false;'
11 )
12 }
13
14 async down(): Promise<void> {
15 this.addSql(
16 'alter table if exists "order_line_item" drop column if exists "is_custom_price";'
17 )
18
19 this.addSql(
20 'alter table if exists "order_shipping_method" drop column if exists "is_custom_amount";'
21 )
22 }
23 }