@reachu/database 1.0.77 → 1.0.79
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/modules/shopcart/Cart.js +1 -1
- package/dist/entity/modules/shopcart/Cart.js.map +1 -1
- package/dist/migrations/1686837392110-cart_shipping_default.d.ts +6 -0
- package/dist/migrations/1686837392110-cart_shipping_default.js +29 -0
- package/dist/migrations/1686837392110-cart_shipping_default.js.map +1 -0
- package/dist/tsconfig.tsbuildinfo +13 -1
- package/package.json +3 -3
- package/src/entity/modules/shopcart/Cart.ts +1 -1
- package/src/migrations/1686837392110-cart_shipping_default.ts +14 -0
|
@@ -40,7 +40,7 @@ __decorate([
|
|
|
40
40
|
__metadata("design:type", Date)
|
|
41
41
|
], Cart.prototype, "deletedAt", void 0);
|
|
42
42
|
__decorate([
|
|
43
|
-
typeorm_1.Column('varchar', { nullable: true
|
|
43
|
+
typeorm_1.Column('varchar', { nullable: true }),
|
|
44
44
|
__metadata("design:type", String)
|
|
45
45
|
], Cart.prototype, "shippingCountry", void 0);
|
|
46
46
|
__decorate([
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Cart.js","sourceRoot":"","sources":["../../../../src/entity/modules/shopcart/Cart.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,qCASiB;AACjB,sEAA8C;AAC9C,0DAAkC;AAClC,0DAAkC;AAClC,sDAA8B;AAG9B,IAAqB,IAAI,GAAzB,MAAqB,IAAK,SAAQ,sBAAY;CA6B7C,CAAA;AA3BC;IADC,gCAAsB,CAAC,MAAM,CAAC;;gCACpB;AAGX;IADC,gBAAM,CAAC,SAAS,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;iDACV;AAG5B;IADC,gBAAM,CAAC,SAAS,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;sCACpB;AAGlB;IADC,gBAAM,CAAC,SAAS,EAAE,EAAE,SAAS,EAAE,EA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OAAO,EAAE,IAAI,EAAE,CAAC;IAC3E,oBAAU,EAAE;;wCACU;AAGvB;IADC,mBAAS,CAAC,GAAG,EAAE,CAAC,kBAAQ,EAAE,CAAC,QAAkB,EAAE,EAAE,CAAC,QAAQ,CAAC,IAAI,EAAE,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;;4CACzD;AA5BR,IAAI;IADxB,gBAAM,EAAE;GACY,IAAI,CA6BxB;kBA7BoB,IAAI"}
|
|
@@ -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.cartShippingDefault1686837392110 = void 0;
|
|
13
|
+
class cartShippingDefault1686837392110 {
|
|
14
|
+
constructor() {
|
|
15
|
+
this.name = 'cartShippingDefault1686837392110';
|
|
16
|
+
}
|
|
17
|
+
up(queryRunner) {
|
|
18
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
19
|
+
yield queryRunner.query(`ALTER TABLE \`cart\` CHANGE \`shipping_country\` \`shipping_country\` varchar(255) NULL`);
|
|
20
|
+
});
|
|
21
|
+
}
|
|
22
|
+
down(queryRunner) {
|
|
23
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
24
|
+
yield queryRunner.query(`ALTER TABLE \`cart\` CHANGE \`shipping_country\` \`shipping_country\` varchar(255) NULL DEFAULT 'NO'`);
|
|
25
|
+
});
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
exports.cartShippingDefault1686837392110 = cartShippingDefault1686837392110;
|
|
29
|
+
//# sourceMappingURL=1686837392110-cart_shipping_default.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"1686837392110-cart_shipping_default.js","sourceRoot":"","sources":["../../src/migrations/1686837392110-cart_shipping_default.ts"],"names":[],"mappings":";;;;;;;;;;;;AAEA,MAAa,gCAAgC;IAA7C;QACI,SAAI,GAAG,kCAAkC,CAAA;IAU7C,CAAC;IARgB,EAAE,CAAC,WAAwB;;YACpC,MAAM,WAAW,CAAC,KAAK,CAAC,yFAAyF,CAAC,CAAC;QACvH,CAAC;KAAA;IAEY,IAAI,CAAC,WAAwB;;YACtC,MAAM,WAAW,CAAC,KAAK,CAAC,sGAAsG,CAAC,CAAC;QACpI,CAAC;KAAA;CAEJ;AAXD,4EAWC"}
|
|
@@ -2532,7 +2532,7 @@
|
|
|
2532
2532
|
"affectsGlobalScope": false
|
|
2533
2533
|
},
|
|
2534
2534
|
"../src/entity/modules/shopcart/cart.ts": {
|
|
2535
|
-
"version": "
|
|
2535
|
+
"version": "84b4499307f11ddde7581eeaf49a0f31adeb4c86ae7d6a989f01e5f2f1e41994",
|
|
2536
2536
|
"signature": "adbc8777a55c898e936e713c8fc967ce21b5383a9d7dbb4f6f2df3667128198a",
|
|
2537
2537
|
"affectsGlobalScope": false
|
|
2538
2538
|
},
|
|
@@ -3291,6 +3291,11 @@
|
|
|
3291
3291
|
"signature": "99a202a7045ba79ab1da4a491827bd45a8ee31fb7f0992253bb978f3be75db31",
|
|
3292
3292
|
"affectsGlobalScope": false
|
|
3293
3293
|
},
|
|
3294
|
+
"../src/migrations/1686837392110-cart_shipping_default.ts": {
|
|
3295
|
+
"version": "39853b8addabb44339316a6b97d54f42e90076e08afb1c8b152b2fc1a5e8e3bb",
|
|
3296
|
+
"signature": "5b52ac63ec6fdb68511463c2cc3785ea6c3bd4a54540433d0416e87b9c7cdc21",
|
|
3297
|
+
"affectsGlobalScope": false
|
|
3298
|
+
},
|
|
3294
3299
|
"../src/migrations/execute/index.ts": {
|
|
3295
3300
|
"version": "8b5bf13d095aeb57afd593adf3d799681176a13c327e2f77e0028e178c4ee3b9",
|
|
3296
3301
|
"signature": "8e609bb71c20b858c77f0e9f90bb1319db8477b13f9f965f1a1e18524bf50881",
|
|
@@ -6132,6 +6137,9 @@
|
|
|
6132
6137
|
"../src/migrations/1686309865248-cart_shipping_country.ts": [
|
|
6133
6138
|
"../node_modules/typeorm/index.d.ts"
|
|
6134
6139
|
],
|
|
6140
|
+
"../src/migrations/1686837392110-cart_shipping_default.ts": [
|
|
6141
|
+
"../node_modules/typeorm/index.d.ts"
|
|
6142
|
+
],
|
|
6135
6143
|
"../src/migrations/execute/index.ts": [
|
|
6136
6144
|
"../src/config/connect.ts"
|
|
6137
6145
|
],
|
|
@@ -8828,6 +8836,9 @@
|
|
|
8828
8836
|
"../src/migrations/1686309865248-cart_shipping_country.ts": [
|
|
8829
8837
|
"../node_modules/typeorm/index.d.ts"
|
|
8830
8838
|
],
|
|
8839
|
+
"../src/migrations/1686837392110-cart_shipping_default.ts": [
|
|
8840
|
+
"../node_modules/typeorm/index.d.ts"
|
|
8841
|
+
],
|
|
8831
8842
|
"../src/migrations/index.ts": [
|
|
8832
8843
|
"../src/migrations/1628474597284-initialschema.ts",
|
|
8833
8844
|
"../src/migrations/1630077596132-removemangopay.ts",
|
|
@@ -9634,6 +9645,7 @@
|
|
|
9634
9645
|
"../src/migrations/1685128263295-external-request-update.ts",
|
|
9635
9646
|
"../src/migrations/1686235086187-fix-multiple-shops.ts",
|
|
9636
9647
|
"../src/migrations/1686309865248-cart_shipping_country.ts",
|
|
9648
|
+
"../src/migrations/1686837392110-cart_shipping_default.ts",
|
|
9637
9649
|
"../src/migrations/execute/index.ts",
|
|
9638
9650
|
"../src/migrations/index.ts",
|
|
9639
9651
|
"../src/repositories/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.79",
|
|
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.79",
|
|
25
|
+
"@reachu/utils": "1.0.79",
|
|
26
26
|
"dotenv": "8.0.0",
|
|
27
27
|
"express": "4.17.1",
|
|
28
28
|
"mysql2": "1.5.2",
|
|
@@ -30,7 +30,7 @@ export default class Cart extends AuditedModel {
|
|
|
30
30
|
@DeleteDateColumn()
|
|
31
31
|
deletedAt: Date;
|
|
32
32
|
|
|
33
|
-
@Column('varchar', { nullable: true
|
|
33
|
+
@Column('varchar', { nullable: true })
|
|
34
34
|
shippingCountry?: string;
|
|
35
35
|
|
|
36
36
|
@ManyToOne(() => User, (user: User) => user.id, { eager: true, onDelete: 'CASCADE' })
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import {MigrationInterface, QueryRunner} from "typeorm";
|
|
2
|
+
|
|
3
|
+
export class cartShippingDefault1686837392110 implements MigrationInterface {
|
|
4
|
+
name = 'cartShippingDefault1686837392110'
|
|
5
|
+
|
|
6
|
+
public async up(queryRunner: QueryRunner): Promise<void> {
|
|
7
|
+
await queryRunner.query(`ALTER TABLE \`cart\` CHANGE \`shipping_country\` \`shipping_country\` varchar(255) NULL`);
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
public async down(queryRunner: QueryRunner): Promise<void> {
|
|
11
|
+
await queryRunner.query(`ALTER TABLE \`cart\` CHANGE \`shipping_country\` \`shipping_country\` varchar(255) NULL DEFAULT 'NO'`);
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
}
|