@reachu/database 1.0.112 → 1.0.115

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.
@@ -7,6 +7,9 @@ export default class ImportedProduct {
7
7
  user: User;
8
8
  product: Product;
9
9
  shopifyId?: number;
10
+ magentoId?: number;
11
+ magentoSku?: string;
12
+ profileMagentoId?: string;
10
13
  wooId?: number;
11
14
  squarespaceId?: string;
12
15
  profileId?: string;
@@ -40,6 +40,18 @@ __decorate([
40
40
  typeorm_1.Column('bigint', { nullable: true }),
41
41
  __metadata("design:type", Number)
42
42
  ], ImportedProduct.prototype, "shopifyId", void 0);
43
+ __decorate([
44
+ typeorm_1.Column('bigint', { nullable: true }),
45
+ __metadata("design:type", Number)
46
+ ], ImportedProduct.prototype, "magentoId", void 0);
47
+ __decorate([
48
+ typeorm_1.Column('varchar', { nullable: true }),
49
+ __metadata("design:type", String)
50
+ ], ImportedProduct.prototype, "magentoSku", void 0);
51
+ __decorate([
52
+ typeorm_1.Column('varchar', { nullable: true }),
53
+ __metadata("design:type", String)
54
+ ], ImportedProduct.prototype, "profileMagentoId", void 0);
43
55
  __decorate([
44
56
  typeorm_1.Column('bigint', { nullable: true }),
45
57
  __metadata("design:type", Number)
@@ -1 +1 @@
1
- {"version":3,"file":"ImportedProduct.js","sourceRoot":"","sources":["../../src/entity/ImportedProduct.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,qCAOiB;AACjB,qDAA2C;AAC3C,kDAA0B;AAC1B,gEAAwC;AAGxC,IAAqB,eAAe,GAApC,MAAqB,eAAe;CAoCnC,CAAA;AAlCC;IADC,gCAAsB,EAAE;;2CACd;AAGX;IADC,0BAAgB,EAAE;8BACR,IAAI;kDAAC;AAIhB;IAFC,mBAAS,CAAC,GAAG,EAAE,CAAC,cAAI,EAAE,EAAE,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,SAAS,EAAE,CAAC;IAC3D,oBAAU,EAAE;8BACP,cAAI;6C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ryRunner } from "typeorm";
2
+ export declare class importedMagento1695122269023 implements MigrationInterface {
3
+ name: string;
4
+ up(queryRunner: QueryRunner): Promise<void>;
5
+ down(queryRunner: QueryRunner): Promise<void>;
6
+ }
@@ -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.importedMagento1695122269023 = void 0;
13
+ class importedMagento1695122269023 {
14
+ constructor() {
15
+ this.name = 'importedMagento1695122269023';
16
+ }
17
+ up(queryRunner) {
18
+ return __awaiter(this, void 0, void 0, function* () {
19
+ yield queryRunner.query(`ALTER TABLE \`imported_product\` ADD \`magento_id\` bigint NULL`);
20
+ yield queryRunner.query(`ALTER TABLE \`imported_product\` ADD \`magento_sku\` varchar(255) NULL`);
21
+ });
22
+ }
23
+ down(queryRunner) {
24
+ return __awaiter(this, void 0, void 0, function* () {
25
+ yield queryRunner.query(`ALTER TABLE \`imported_product\` DROP COLUMN \`magento_sku\``);
26
+ yield queryRunner.query(`ALTER TABLE \`imported_product\` DROP COLUMN \`magento_id\``);
27
+ });
28
+ }
29
+ }
30
+ exports.importedMagento1695122269023 = importedMagento1695122269023;
31
+ //# sourceMappingURL=1695122269023-imported_magento.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"1695122269023-imported_magento.js","sourceRoot":"","sources":["../../src/migrations/1695122269023-imported_magento.ts"],"names":[],"mappings":";;;;;;;;;;;;AAEA,MAAa,4BAA4B;IAAzC;QACI,SAAI,GAAG,8BAA8B,CAAA;IAYzC,CAAC;IAVgB,EAAE,CAAC,WAAwB;;YACpC,MAAM,WAAW,CAAC,KAAK,CAAC,iEAAiE,CAAC,CAAC;YAC3F,MAAM,WAAW,CAAC,KAAK,CAAC,wEAAwE,CAAC,CAAC;QACtG,CAAC;KAAA;IAEY,IAAI,CAAC,WAAwB;;YACtC,MAAM,WAAW,CAAC,KAAK,CAAC,8DAA8D,CAAC,CAAC;YACxF,MAAM,WAAW,CAAC,KAAK,CAAC,6DAA6D,CAAC,CAAC;QAC3F,CAAC;KAAA;CAEJ;AAbD,oEAaC"}
@@ -0,0 +1,6 @@
1
+ import { MigrationInterface, QueryRunner } from "typeorm";
2
+ export declare class importedMagento11695123846329 implements MigrationInterface {
3
+ name: string;
4
+ up(queryRunner: QueryRunner): Promise<void>;
5
+ down(queryRunner: QueryRunner): Promise<void>;
6
+ }
@@ -0,0 +1,33 @@
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.importedMagento11695123846329 = void 0;
13
+ class importedMagento11695123846329 {
14
+ constructor() {
15
+ this.name = 'importedMagento11695123846329';
16
+ }
17
+ up(queryRunner) {
18
+ return __awaiter(this, void 0, void 0, function* () {
19
+ yield queryRunner.query(`ALTER TABLE \`imported_product\` ADD \`magento_id\` bigint NULL`);
20
+ yield queryRunner.query(`ALTER TABLE \`imported_product\` ADD \`magento_sku\` varchar(255) NULL`);
21
+ yield queryRunner.query(`ALTER TABLE \`imported_product\` ADD \`profile_magento_id\` varchar(255) NULL`);
22
+ });
23
+ }
24
+ down(queryRunner) {
25
+ return __awaiter(this, void 0, void 0, function* () {
26
+ yield queryRunner.query(`ALTER TABLE \`imported_product\` DROP COLUMN \`profile_magento_id\``);
27
+ yield queryRunner.query(`ALTER TABLE \`imported_product\` DROP COLUMN \`magento_sku\``);
28
+ yield queryRunner.query(`ALTER TABLE \`imported_product\` DROP COLUMN \`magento_id\``);
29
+ });
30
+ }
31
+ }
32
+ exports.importedMagento11695123846329 = importedMagento11695123846329;
33
+ //# sourceMappingURL=1695123846329-imported_magento_1.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"1695123846329-imported_magento_1.js","sourceRoot":"","sources":["../../src/migrations/1695123846329-imported_magento_1.ts"],"names":[],"mappings":";;;;;;;;;;;;AAEA,MAAa,6BAA6B;IAA1C;QACI,SAAI,GAAG,+BAA+B,CAAA;IAc1C,CAAC;IAZgB,EAAE,CAAC,WAAwB;;YACpC,MAAM,WAAW,CAAC,KAAK,CAAC,iEAAiE,CAAC,CAAC;YAC3F,MAAM,WAAW,CAAC,KAAK,CAAC,wEAAwE,CAAC,CAAC;YAClG,MAAM,WAAW,CAAC,KAAK,CAAC,+EAA+E,CAAC,CAAC;QAC7G,CAAC;KAAA;IAEY,IAAI,CAAC,WAAwB;;YACtC,MAAM,WAAW,CAAC,KAAK,CAAC,qEAAqE,CAAC,CAAC;YAC/F,MAAM,WAAW,CAAC,KAAK,CAAC,8DAA8D,CAAC,CAAC;YACxF,MAAM,WAAW,CAAC,KAAK,CAAC,6DAA6D,CAAC,CAAC;QAC3F,CAAC;KAAA;CAEJ;AAfD,sEAeC"}
@@ -2417,8 +2417,8 @@
2417
2417
  "affectsGlobalScope": false
2418
2418
  },
2419
2419
  "../src/entity/importedproduct.ts": {
2420
- "version": "8f9cb6bf66f203519c1a2ed09c997d132eb401ee0108b5042751ca556d89c966",
2421
- "signature": "e9b48b9b5b47f7a3626ba1ccec58d7fc386dbf08561909014a88e31bd29ce697",
2420
+ "version": "110ac8ceecb7ae64aa807b9588d274ff2a023fd3e50d6456234bce74a8017823",
2421
+ "signature": "7bf17cca9ae7e345f842523f6b7c3a1bfbec42f3ce8d439b5f1d68a7d70de7f4",
2422
2422
  "affectsGlobalScope": false
2423
2423
  },
2424
2424
  "../src/staticdata/currency.ts": {
@@ -3511,6 +3511,16 @@
3511
3511
  "signature": "a12b3714050bd58a48986a39d5b50cd09fa0e2c5ebe714e7913c75a95d31248d",
3512
3512
  "affectsGlobalScope": false
3513
3513
  },
3514
+ "../src/migrations/1695122269023-imported_magento.ts": {
3515
+ "version": "e3cf9b86b566fd61b4a3cd714e1965e1bb0d58369abfd05cb155bbb84d8031ef",
3516
+ "signature": "291ded748e5c781ea1a320b63b31ff77a26bf6e89936fe0de9b0075383542633",
3517
+ "affectsGlobalScope": false
3518
+ },
3519
+ "../src/migrations/1695123846329-imported_magento_1.ts": {
3520
+ "version": "041792231c6b7b810677f6046ceb107063ae01e8b27a89b88d5b7e8141343986",
3521
+ "signature": "5b95f8e8603edb11d8099947cab5f931a6406f5503c21c42ebdb75ad042e0994",
3522
+ "affectsGlobalScope": false
3523
+ },
3514
3524
  "../src/migrations/execute/index.ts": {
3515
3525
  "version": "8b5bf13d095aeb57afd593adf3d799681176a13c327e2f77e0028e178c4ee3b9",
3516
3526
  "signature": "8e609bb71c20b858c77f0e9f90bb1319db8477b13f9f965f1a1e18524bf50881",
@@ -6515,6 +6525,12 @@
6515
6525
  "../src/migrations/1694787189040-flag-digital.ts": [
6516
6526
  "../node_modules/typeorm/index.d.ts"
6517
6527
  ],
6528
+ "../src/migrations/1695122269023-imported_magento.ts": [
6529
+ "../node_modules/typeorm/index.d.ts"
6530
+ ],
6531
+ "../src/migrations/1695123846329-imported_magento_1.ts": [
6532
+ "../node_modules/typeorm/index.d.ts"
6533
+ ],
6518
6534
  "../src/migrations/execute/index.ts": [
6519
6535
  "../src/config/connect.ts"
6520
6536
  ],
@@ -9374,6 +9390,12 @@
9374
9390
  "../src/migrations/1694787189040-flag-digital.ts": [
9375
9391
  "../node_modules/typeorm/index.d.ts"
9376
9392
  ],
9393
+ "../src/migrations/1695122269023-imported_magento.ts": [
9394
+ "../node_modules/typeorm/index.d.ts"
9395
+ ],
9396
+ "../src/migrations/1695123846329-imported_magento_1.ts": [
9397
+ "../node_modules/typeorm/index.d.ts"
9398
+ ],
9377
9399
  "../src/migrations/index.ts": [
9378
9400
  "../src/migrations/1628474597284-initialschema.ts",
9379
9401
  "../src/migrations/1630077596132-removemangopay.ts",
@@ -10233,6 +10255,8 @@
10233
10255
  "../src/migrations/1694451010874-promote_to_production_11_09_23__01.ts",
10234
10256
  "../src/migrations/1694661125001-user-channel-and-megento-connection.ts",
10235
10257
  "../src/migrations/1694787189040-flag-digital.ts",
10258
+ "../src/migrations/1695122269023-imported_magento.ts",
10259
+ "../src/migrations/1695123846329-imported_magento_1.ts",
10236
10260
  "../src/migrations/execute/index.ts",
10237
10261
  "../src/migrations/index.ts",
10238
10262
  "../src/repositories/discount/index.ts",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@reachu/database",
3
- "version": "1.0.112",
3
+ "version": "1.0.115",
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.112",
25
- "@reachu/utils": "1.0.112",
24
+ "@reachu/logger": "1.0.115",
25
+ "@reachu/utils": "1.0.115",
26
26
  "dotenv": "8.0.0",
27
27
  "express": "4.17.1",
28
28
  "mysql2": "1.5.2",
@@ -29,6 +29,15 @@ export default class ImportedProduct {
29
29
  @Column('bigint', { nullable: true })
30
30
  shopifyId?: number;
31
31
 
32
+ @Column('bigint', { nullable: true })
33
+ magentoId?: number;
34
+
35
+ @Column('varchar', { nullable: true })
36
+ magentoSku?: string;
37
+
38
+ @Column('varchar', { nullable: true })
39
+ profileMagentoId?: string;
40
+
32
41
  @Column('bigint', { nullable: true })
33
42
  wooId?: number;
34
43
 
@@ -0,0 +1,16 @@
1
+ import {MigrationInterface, QueryRunner} from "typeorm";
2
+
3
+ export class importedMagento1695122269023 implements MigrationInterface {
4
+ name = 'importedMagento1695122269023'
5
+
6
+ public async up(queryRunner: QueryRunner): Promise<void> {
7
+ await queryRunner.query(`ALTER TABLE \`imported_product\` ADD \`magento_id\` bigint NULL`);
8
+ await queryRunner.query(`ALTER TABLE \`imported_product\` ADD \`magento_sku\` varchar(255) NULL`);
9
+ }
10
+
11
+ public async down(queryRunner: QueryRunner): Promise<void> {
12
+ await queryRunner.query(`ALTER TABLE \`imported_product\` DROP COLUMN \`magento_sku\``);
13
+ await queryRunner.query(`ALTER TABLE \`imported_product\` DROP COLUMN \`magento_id\``);
14
+ }
15
+
16
+ }
@@ -0,0 +1,18 @@
1
+ import {MigrationInterface, QueryRunner} from "typeorm";
2
+
3
+ export class importedMagento11695123846329 implements MigrationInterface {
4
+ name = 'importedMagento11695123846329'
5
+
6
+ public async up(queryRunner: QueryRunner): Promise<void> {
7
+ await queryRunner.query(`ALTER TABLE \`imported_product\` ADD \`magento_id\` bigint NULL`);
8
+ await queryRunner.query(`ALTER TABLE \`imported_product\` ADD \`magento_sku\` varchar(255) NULL`);
9
+ await queryRunner.query(`ALTER TABLE \`imported_product\` ADD \`profile_magento_id\` varchar(255) NULL`);
10
+ }
11
+
12
+ public async down(queryRunner: QueryRunner): Promise<void> {
13
+ await queryRunner.query(`ALTER TABLE \`imported_product\` DROP COLUMN \`profile_magento_id\``);
14
+ await queryRunner.query(`ALTER TABLE \`imported_product\` DROP COLUMN \`magento_sku\``);
15
+ await queryRunner.query(`ALTER TABLE \`imported_product\` DROP COLUMN \`magento_id\``);
16
+ }
17
+
18
+ }