@reachu/database 1.0.119 → 1.0.121
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/entity/ProductDigital.d.ts +1 -0
- package/dist/entity/ProductDigital.js +4 -0
- package/dist/entity/ProductDigital.js.map +1 -1
- package/dist/entity/modules/shopcart/PriceData.d.ts +1 -0
- package/dist/entity/modules/shopcart/PriceData.js +4 -0
- package/dist/entity/modules/shopcart/PriceData.js.map +1 -1
- package/dist/migrations/1696268533737-digital_update_02.d.ts +6 -0
- package/dist/migrations/1696268533737-digital_update_02.js +31 -0
- package/dist/migrations/1696268533737-digital_update_02.js.map +1 -0
- package/dist/migrations/1696608295188-compareat-line-items-1.d.ts +6 -0
- package/dist/migrations/1696608295188-compareat-line-items-1.js +29 -0
- package/dist/migrations/1696608295188-compareat-line-items-1.js.map +1 -0
- package/dist/tsconfig.tsbuildinfo +28 -4
- package/package.json +3 -3
- package/src/entity/ProductDigital.ts +3 -0
- package/src/entity/modules/shopcart/PriceData.ts +3 -0
- package/src/migrations/1696268533737-digital_update_02.ts +16 -0
- package/src/migrations/1696608295188-compareat-line-items-1.ts +14 -0
|
@@ -56,6 +56,10 @@ __decorate([
|
|
|
56
56
|
typeorm_1.Column('integer', { nullable: true }),
|
|
57
57
|
__metadata("design:type", Number)
|
|
58
58
|
], ProductDigital.prototype, "type", void 0);
|
|
59
|
+
__decorate([
|
|
60
|
+
typeorm_1.Column('integer', { nullable: true }),
|
|
61
|
+
__metadata("design:type", Number)
|
|
62
|
+
], ProductDigital.prototype, "position", void 0);
|
|
59
63
|
__decorate([
|
|
60
64
|
typeorm_1.OneToOne(() => ProductDigital_1, (productDigital) => productDigital.id, {
|
|
61
65
|
eager: false,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ProductDigital.js","sourceRoot":"","sources":["../../src/entity/ProductDigital.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,qCAQiB;AACjB,kEAA0C;AAC1C,qDAA2C;AAC3C,iDAAuC;AAEvC,IAAY,KAIX;AAJD,WAAY,KAAK;IACf,iDAAgB,CAAA;IAChB,qCAAU,CAAA;IACV,iCAAQ,CAAA;AACV,CAAC,EAJW,KAAK,GAAL,aAAK,KAAL,aAAK,QAIhB;AAED,IAAY,UAIX;AAJD,WAAY,UAAU;IACpB,yCAAO,CAAA;IACP,uCAAM,CAAA;IACN,qDAAa,CAAA;AACf,CAAC,EAJW,UAAU,GAAV,kBAAU,KAAV,kBAAU,QAIrB;AAGD,IAAqB,cAAc,sBAAnC,MAAqB,cAAe,SAAQ,sBAAY;
|
|
1
|
+
{"version":3,"file":"ProductDigital.js","sourceRoot":"","sources":["../../src/entity/ProductDigital.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,qCAQiB;AACjB,kEAA0C;AAC1C,qDAA2C;AAC3C,iDAAuC;AAEvC,IAAY,KAIX;AAJD,WAAY,KAAK;IACf,iDAAgB,CAAA;IAChB,qCAAU,CAAA;IACV,iCAAQ,CAAA;AACV,CAAC,EAJW,KAAK,GAAL,aAAK,KAAL,aAAK,QAIhB;AAED,IAAY,UAIX;AAJD,WAAY,UAAU;IACpB,yCAAO,CAAA;IACP,uCAAM,CAAA;IACN,qDAAa,CAAA;AACf,CAAC,EAJW,UAAU,GAAV,kBAAU,KAAV,kBAAU,QAIrB;AAGD,IAAqB,cAAc,sBAAnC,MAAqB,cAAe,SAAQ,sBAAY;CA8CvD,CAAA;AA5CC;IADC,gCAAsB,EAAE;;0CACd;AAGX;IADC,0BAAgB,EAAE;8BACR,IAAI;iDAAC;AAGhB;IADC,gBAAM,CAAC,MAAM,EAAE,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC;;gDACnB;AAGjB;IADC,gBAAM,CAAC,SAAS,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;iDACpB;AAGlB;IADC,gBAAM,CAAC,SAAS,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;iDACT;AAG7B;IADC,gBAAM,CAAC,SAAS,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;4CACnB;AAGnB;IADC,gBAAM,CAAC,SAAS,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;gDACrB;AAOjB;IALC,kBAAQ,CAAC,GAAG,EAAE,CAAC,gBAAc,EAAE,CAAC,cAA8B,EAAE,EAAE,CAAC,cAAc,CAAC,EAAE,EAAE;QACrF,KAAK,EAAE,KAAK;QACZ,QAAQ,EAAE,IAAI;KACf,CAAC;IACD,oBAAU,EAAE;8BACG,cAAc;sDAAC;AAG/B;IADC,gBAAM,CAAC,GAAG,EAAE,CAAC,oBAAK,EAAE,EAAE,MAAM,EAAE,QAAQ,EAAE,CAAC;8BACnC,oBAAK;6CAAC;AAGb;IADC,gBAAM,CAAC,SAAS,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;sDACf;AAGvB;IADC,gBAAM,CAAC,UAAU,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;8BACtB,IAAI;uDAAC;AAMtB;IAJC,mBAAS,CAAC,GAAG,EAAE,CAAC,wBAAO,EAAE,CAAC,OAAgB,EAAE,EAAE,CAAC,OAAO,CAAC,EAAE,EAAE;QAC1D,KAAK,EAAE,KAAK;KACb,CAAC;IACD,oBAAU,EAAE;8BACJ,wBAAO;+CAAC;AAGjB;IADC,gBAAM,CAAC,MAAM,EAAE,EAAE,QAAQ,EAAE,KAAK,EAAE,CAAC;;4CACvB;AA7CM,cAAc;IADlC,gBAAM,EAAE;GACY,cAAc,CA8ClC;kBA9CoB,cAAc"}
|
|
@@ -37,6 +37,10 @@ __decorate([
|
|
|
37
37
|
typeorm_1.OneToOne(() => CartItem_1.default, (cartItem) => cartItem.priceData, { eager: true }),
|
|
38
38
|
__metadata("design:type", CartItem_1.default)
|
|
39
39
|
], PriceData.prototype, "cartItem", void 0);
|
|
40
|
+
__decorate([
|
|
41
|
+
typeorm_1.Column('decimal', { precision: 10, scale: 2, default: 0, nullable: true }),
|
|
42
|
+
__metadata("design:type", Number)
|
|
43
|
+
], PriceData.prototype, "compareAt", void 0);
|
|
40
44
|
PriceData = __decorate([
|
|
41
45
|
typeorm_1.Entity()
|
|
42
46
|
], PriceData);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PriceData.js","sourceRoot":"","sources":["../../../../src/entity/modules/shopcart/PriceData.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,qCAAuF;AACvF,0DAAkC;AAGlC,IAAa,SAAS,GAAtB,MAAa,SAAS;
|
|
1
|
+
{"version":3,"file":"PriceData.js","sourceRoot":"","sources":["../../../../src/entity/modules/shopcart/PriceData.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,qCAAuF;AACvF,0DAAkC;AAGlC,IAAa,SAAS,GAAtB,MAAa,SAAS;CAkBrB,CAAA;AAhBC;IADC,gCAAsB,CAAC,MAAM,CAAC;;qCACpB;AAGX;IADC,gBAAM,CAAC,SAAS,EAAE,EAAE,SAAS,EAAE,EAAE,EAAE,KAAK,EAAE,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC;;4CACxC;AAGnB;IADC,gBAAM,CAAC,SAAS,EAAE,EAAE,SAAS,EAAE,EAAE,EAAE,KAAK,EAAE,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC;;sCAC9C;AAGb;IADC,gBAAM,CAAC,SAAS,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;2CACpB;AAGlB;IADC,kBAAQ,CAAC,GAAG,EAAE,CAAC,kBAAQ,EAAE,CAAC,QAAQ,EAAE,EAAE,CAAC,QAAQ,CAAC,SAAS,EAAE,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC;8BAClE,kBAAQ;2CAAC;AAGnB;IADC,gBAAM,CAAC,SAAS,EAAE,EAAE,SAAS,EAAE,EAAE,EAAE,KAAK,EAAE,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;4CACxD;AAjBR,SAAS;IADrB,gBAAM,EAAE;GACI,SAAS,CAkBrB;AAlBY,8BAAS"}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.digitalUpdate021696268533737 = void 0;
|
|
13
|
+
class digitalUpdate021696268533737 {
|
|
14
|
+
constructor() {
|
|
15
|
+
this.name = 'digitalUpdate021696268533737';
|
|
16
|
+
}
|
|
17
|
+
up(queryRunner) {
|
|
18
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
19
|
+
yield queryRunner.query(`DROP INDEX \`IDX_c6bbcf34d07fb60f39b9852f2a\` ON \`product_digital\``);
|
|
20
|
+
yield queryRunner.query(`ALTER TABLE \`product_digital\` ADD \`position\` int NULL`);
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
down(queryRunner) {
|
|
24
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
25
|
+
yield queryRunner.query(`ALTER TABLE \`product_digital\` DROP COLUMN \`position\``);
|
|
26
|
+
yield queryRunner.query(`CREATE UNIQUE INDEX \`IDX_c6bbcf34d07fb60f39b9852f2a\` ON \`product_digital\` (\`product_digital_id\`)`);
|
|
27
|
+
});
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
exports.digitalUpdate021696268533737 = digitalUpdate021696268533737;
|
|
31
|
+
//# sourceMappingURL=1696268533737-digital_update_02.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"1696268533737-digital_update_02.js","sourceRoot":"","sources":["../../src/migrations/1696268533737-digital_update_02.ts"],"names":[],"mappings":";;;;;;;;;;;;AAEA,MAAa,4BAA4B;IAAzC;QACI,SAAI,GAAG,8BAA8B,CAAA;IAYzC,CAAC;IAVgB,EAAE,CAAC,WAAwB;;YACpC,MAAM,WAAW,CAAC,KAAK,CAAC,sEAAsE,CAAC,CAAC;YAChG,MAAM,WAAW,CAAC,KAAK,CAAC,2DAA2D,CAAC,CAAC;QACzF,CAAC;KAAA;IAEY,IAAI,CAAC,WAAwB;;YACtC,MAAM,WAAW,CAAC,KAAK,CAAC,0DAA0D,CAAC,CAAC;YACpF,MAAM,WAAW,CAAC,KAAK,CAAC,wGAAwG,CAAC,CAAC;QACtI,CAAC;KAAA;CAEJ;AAbD,oEAaC"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.compareatLineItems11696608295188 = void 0;
|
|
13
|
+
class compareatLineItems11696608295188 {
|
|
14
|
+
constructor() {
|
|
15
|
+
this.name = 'compareatLineItems11696608295188';
|
|
16
|
+
}
|
|
17
|
+
up(queryRunner) {
|
|
18
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
19
|
+
yield queryRunner.query(`ALTER TABLE \`price_data\` ADD \`compare_at\` decimal(10,2) NULL DEFAULT '0.00'`);
|
|
20
|
+
});
|
|
21
|
+
}
|
|
22
|
+
down(queryRunner) {
|
|
23
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
24
|
+
yield queryRunner.query(`ALTER TABLE \`price_data\` DROP COLUMN \`compare_at\``);
|
|
25
|
+
});
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
exports.compareatLineItems11696608295188 = compareatLineItems11696608295188;
|
|
29
|
+
//# sourceMappingURL=1696608295188-compareat-line-items-1.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"1696608295188-compareat-line-items-1.js","sourceRoot":"","sources":["../../src/migrations/1696608295188-compareat-line-items-1.ts"],"names":[],"mappings":";;;;;;;;;;;;AAEA,MAAa,gCAAgC;IAA7C;QACI,SAAI,GAAG,kCAAkC,CAAA;IAU7C,CAAC;IARgB,EAAE,CAAC,WAAwB;;YACpC,MAAM,WAAW,CAAC,KAAK,CAAC,iFAAiF,CAAC,CAAC;QAC/G,CAAC;KAAA;IAEY,IAAI,CAAC,WAAwB;;YACtC,MAAM,WAAW,CAAC,KAAK,CAAC,uDAAuD,CAAC,CAAC;QACrF,CAAC;KAAA;CAEJ;AAXD,4EAWC"}
|
|
@@ -2377,8 +2377,8 @@
|
|
|
2377
2377
|
"affectsGlobalScope": false
|
|
2378
2378
|
},
|
|
2379
2379
|
"../src/entity/modules/shopcart/pricedata.ts": {
|
|
2380
|
-
"version": "
|
|
2381
|
-
"signature": "
|
|
2380
|
+
"version": "d853ab4b2f15e3fa894ed7ab16582fb0e3f71b2fbbc79367cf2d3c63bc977e50",
|
|
2381
|
+
"signature": "9d67211ef476a0b445369b10344f378099a03760cdac17823d7420fc8ba99a9f",
|
|
2382
2382
|
"affectsGlobalScope": false
|
|
2383
2383
|
},
|
|
2384
2384
|
"../src/entity/modules/shopcart/checkoutbillingaddress.ts": {
|
|
@@ -2652,8 +2652,8 @@
|
|
|
2652
2652
|
"affectsGlobalScope": false
|
|
2653
2653
|
},
|
|
2654
2654
|
"../src/entity/productdigital.ts": {
|
|
2655
|
-
"version": "
|
|
2656
|
-
"signature": "
|
|
2655
|
+
"version": "a94b04ba80eaf4b01e00f2680d7debc86087e653f1d7629692ab0dabec165279",
|
|
2656
|
+
"signature": "458b3ad0e3b76f8c3c38d40f6109d2302b60912138f9b5e2dccadf9a236c8a72",
|
|
2657
2657
|
"affectsGlobalScope": false
|
|
2658
2658
|
},
|
|
2659
2659
|
"../src/entity/modules/templates/endpointtemplateecommerce.ts": {
|
|
@@ -3546,6 +3546,16 @@
|
|
|
3546
3546
|
"signature": "660f9871aa3be94831d2cd273000d246afd1819aa2832359a1daa1be6e03ce15",
|
|
3547
3547
|
"affectsGlobalScope": false
|
|
3548
3548
|
},
|
|
3549
|
+
"../src/migrations/1696268533737-digital_update_02.ts": {
|
|
3550
|
+
"version": "1d5e303c9a7957c6fb006e1f529dfe565e234e12bea667b8b2d1d10a2dec6bcb",
|
|
3551
|
+
"signature": "c6f82cb47d34f7da93d240fbe9d790acf46fe51ae6c48ea64cc7672b45ad3c13",
|
|
3552
|
+
"affectsGlobalScope": false
|
|
3553
|
+
},
|
|
3554
|
+
"../src/migrations/1696608295188-compareat-line-items-1.ts": {
|
|
3555
|
+
"version": "32e03b46ba8fda151b751a035c3e40b1f2474da1da1eb6cf9312b5b02e6ebfb4",
|
|
3556
|
+
"signature": "ca41f2fd243c5b0fa4edfbd652cb78d4c4586aec69d12ed299e611c977b1e717",
|
|
3557
|
+
"affectsGlobalScope": false
|
|
3558
|
+
},
|
|
3549
3559
|
"../src/migrations/execute/index.ts": {
|
|
3550
3560
|
"version": "8b5bf13d095aeb57afd593adf3d799681176a13c327e2f77e0028e178c4ee3b9",
|
|
3551
3561
|
"signature": "8e609bb71c20b858c77f0e9f90bb1319db8477b13f9f965f1a1e18524bf50881",
|
|
@@ -6575,6 +6585,12 @@
|
|
|
6575
6585
|
"../src/migrations/1696266360829-digital_update_01.ts": [
|
|
6576
6586
|
"../node_modules/typeorm/index.d.ts"
|
|
6577
6587
|
],
|
|
6588
|
+
"../src/migrations/1696268533737-digital_update_02.ts": [
|
|
6589
|
+
"../node_modules/typeorm/index.d.ts"
|
|
6590
|
+
],
|
|
6591
|
+
"../src/migrations/1696608295188-compareat-line-items-1.ts": [
|
|
6592
|
+
"../node_modules/typeorm/index.d.ts"
|
|
6593
|
+
],
|
|
6578
6594
|
"../src/migrations/execute/index.ts": [
|
|
6579
6595
|
"../src/config/connect.ts"
|
|
6580
6596
|
],
|
|
@@ -9459,6 +9475,12 @@
|
|
|
9459
9475
|
"../src/migrations/1696266360829-digital_update_01.ts": [
|
|
9460
9476
|
"../node_modules/typeorm/index.d.ts"
|
|
9461
9477
|
],
|
|
9478
|
+
"../src/migrations/1696268533737-digital_update_02.ts": [
|
|
9479
|
+
"../node_modules/typeorm/index.d.ts"
|
|
9480
|
+
],
|
|
9481
|
+
"../src/migrations/1696608295188-compareat-line-items-1.ts": [
|
|
9482
|
+
"../node_modules/typeorm/index.d.ts"
|
|
9483
|
+
],
|
|
9462
9484
|
"../src/migrations/index.ts": [
|
|
9463
9485
|
"../src/migrations/1628474597284-initialschema.ts",
|
|
9464
9486
|
"../src/migrations/1630077596132-removemangopay.ts",
|
|
@@ -10326,6 +10348,8 @@
|
|
|
10326
10348
|
"../src/migrations/1695907880854-digital-product-v-2.ts",
|
|
10327
10349
|
"../src/migrations/1696260773644-digital_update.ts",
|
|
10328
10350
|
"../src/migrations/1696266360829-digital_update_01.ts",
|
|
10351
|
+
"../src/migrations/1696268533737-digital_update_02.ts",
|
|
10352
|
+
"../src/migrations/1696608295188-compareat-line-items-1.ts",
|
|
10329
10353
|
"../src/migrations/execute/index.ts",
|
|
10330
10354
|
"../src/migrations/index.ts",
|
|
10331
10355
|
"../src/repositories/discount/index.ts",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@reachu/database",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.121",
|
|
4
4
|
"description": "reachu-database",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -21,8 +21,8 @@
|
|
|
21
21
|
"author": "reachu",
|
|
22
22
|
"license": "ISC",
|
|
23
23
|
"dependencies": {
|
|
24
|
-
"@reachu/logger": "1.0.
|
|
25
|
-
"@reachu/utils": "1.0.
|
|
24
|
+
"@reachu/logger": "1.0.121",
|
|
25
|
+
"@reachu/utils": "1.0.121",
|
|
26
26
|
"dotenv": "8.0.0",
|
|
27
27
|
"express": "4.17.1",
|
|
28
28
|
"mysql2": "1.5.2",
|
|
@@ -43,6 +43,9 @@ export default class ProductDigital extends AuditedModel {
|
|
|
43
43
|
@Column('integer', { nullable: true })
|
|
44
44
|
type: _type | null;
|
|
45
45
|
|
|
46
|
+
@Column('integer', { nullable: true })
|
|
47
|
+
position: number;
|
|
48
|
+
|
|
46
49
|
@OneToOne(() => ProductDigital, (productDigital: ProductDigital) => productDigital.id, {
|
|
47
50
|
eager: false,
|
|
48
51
|
nullable: true,
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import {MigrationInterface, QueryRunner} from "typeorm";
|
|
2
|
+
|
|
3
|
+
export class digitalUpdate021696268533737 implements MigrationInterface {
|
|
4
|
+
name = 'digitalUpdate021696268533737'
|
|
5
|
+
|
|
6
|
+
public async up(queryRunner: QueryRunner): Promise<void> {
|
|
7
|
+
await queryRunner.query(`DROP INDEX \`IDX_c6bbcf34d07fb60f39b9852f2a\` ON \`product_digital\``);
|
|
8
|
+
await queryRunner.query(`ALTER TABLE \`product_digital\` ADD \`position\` int NULL`);
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
public async down(queryRunner: QueryRunner): Promise<void> {
|
|
12
|
+
await queryRunner.query(`ALTER TABLE \`product_digital\` DROP COLUMN \`position\``);
|
|
13
|
+
await queryRunner.query(`CREATE UNIQUE INDEX \`IDX_c6bbcf34d07fb60f39b9852f2a\` ON \`product_digital\` (\`product_digital_id\`)`);
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import {MigrationInterface, QueryRunner} from "typeorm";
|
|
2
|
+
|
|
3
|
+
export class compareatLineItems11696608295188 implements MigrationInterface {
|
|
4
|
+
name = 'compareatLineItems11696608295188'
|
|
5
|
+
|
|
6
|
+
public async up(queryRunner: QueryRunner): Promise<void> {
|
|
7
|
+
await queryRunner.query(`ALTER TABLE \`price_data\` ADD \`compare_at\` decimal(10,2) NULL DEFAULT '0.00'`);
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
public async down(queryRunner: QueryRunner): Promise<void> {
|
|
11
|
+
await queryRunner.query(`ALTER TABLE \`price_data\` DROP COLUMN \`compare_at\``);
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
}
|