@reachu/database 1.0.1 → 1.0.3

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.
Files changed (47) hide show
  1. package/dist/entity/Attribute.d.ts +8 -0
  2. package/dist/entity/Attribute.js +41 -0
  3. package/dist/entity/Attribute.js.map +1 -0
  4. package/dist/entity/Category.d.ts +7 -1
  5. package/dist/entity/Category.js +23 -1
  6. package/dist/entity/Category.js.map +1 -1
  7. package/dist/entity/CategoryImages.d.ts +12 -0
  8. package/dist/entity/CategoryImages.js +57 -0
  9. package/dist/entity/CategoryImages.js.map +1 -0
  10. package/dist/entity/Product.entity.d.ts +2 -0
  11. package/dist/entity/Product.entity.js +6 -0
  12. package/dist/entity/Product.entity.js.map +1 -1
  13. package/dist/entity/ProductAttribute.d.ts +9 -0
  14. package/dist/entity/ProductAttribute.js +49 -0
  15. package/dist/entity/ProductAttribute.js.map +1 -0
  16. package/dist/entity/Subcategory.d.ts +3 -1
  17. package/dist/entity/Subcategory.js +6 -1
  18. package/dist/entity/Subcategory.js.map +1 -1
  19. package/dist/entity/index.d.ts +4 -1
  20. package/dist/entity/index.js +7 -1
  21. package/dist/entity/index.js.map +1 -1
  22. package/dist/helpers/products/storage/search.d.ts +1 -0
  23. package/dist/migrations/1677706695399-promote_to_production_2023_01_03.d.ts +6 -0
  24. package/dist/migrations/1677706695399-promote_to_production_2023_01_03.js +49 -0
  25. package/dist/migrations/1677706695399-promote_to_production_2023_01_03.js.map +1 -0
  26. package/dist/migrations/1677763068338-task-1032V1.d.ts +6 -0
  27. package/dist/migrations/1677763068338-task-1032V1.js +51 -0
  28. package/dist/migrations/1677763068338-task-1032V1.js.map +1 -0
  29. package/dist/migrations/1677764464274-task-1032V2.d.ts +6 -0
  30. package/dist/migrations/1677764464274-task-1032V2.js +33 -0
  31. package/dist/migrations/1677764464274-task-1032V2.js.map +1 -0
  32. package/dist/repositories/index.d.ts +9 -0
  33. package/dist/repositories/index.js +23 -2
  34. package/dist/repositories/index.js.map +1 -1
  35. package/dist/tsconfig.tsbuildinfo +114 -11
  36. package/package.json +3 -3
  37. package/src/entity/Attribute.ts +30 -0
  38. package/src/entity/Category.ts +28 -2
  39. package/src/entity/CategoryImages.ts +38 -0
  40. package/src/entity/Product.entity.ts +9 -0
  41. package/src/entity/ProductAttribute.ts +27 -0
  42. package/src/entity/Subcategory.ts +6 -2
  43. package/src/entity/index.ts +7 -0
  44. package/src/migrations/1677706695399-promote_to_production_2023_01_03.ts +34 -0
  45. package/src/migrations/1677763068338-task-1032V1.ts +57 -0
  46. package/src/migrations/1677764464274-task-1032V2.ts +18 -0
  47. package/src/repositories/index.ts +13 -0
@@ -0,0 +1 @@
1
+ {"version":3,"file":"1677764464274-task-1032V2.js","sourceRoot":"","sources":["../../src/migrations/1677764464274-task-1032V2.ts"],"names":[],"mappings":";;;;;;;;;;;;AAEA,MAAa,uBAAuB;IAApC;QACI,SAAI,GAAG,yBAAyB,CAAA;IAcpC,CAAC;IAZgB,EAAE,CAAC,WAAwB;;YACpC,MAAM,WAAW,CAAC,KAAK,CAAC,kGAAkG,CAAC,CAAC;YAC5H,MAAM,WAAW,CAAC,KAAK,CAAC,iIAAiI,CAAC,CAAC;YAC3J,MAAM,WAAW,CAAC,KAAK,CAAC,iEAAiE,CAAC,CAAC;QAC/F,CAAC;KAAA;IAEY,IAAI,CAAC,WAAwB;;YACtC,MAAM,WAAW,CAAC,KAAK,CAAC,wDAAwD,CAAC,CAAC;YAClF,MAAM,WAAW,CAAC,KAAK,CAAC,wDAAwD,CAAC,CAAC;YAClF,MAAM,WAAW,CAAC,KAAK,CAAC,wDAAwD,CAAC,CAAC;QACtF,CAAC;KAAA;CAEJ;AAfD,0DAeC"}
@@ -49,9 +49,18 @@ import ExchangeRate from '../entity/ExchangeRate';
49
49
  import CustomVariant from '../entity/CustomVariant';
50
50
  import { CustomProduct } from '../entity/CustomProduct';
51
51
  import CustomProductImage from '../entity/CustomProductImage';
52
+ import Attribute from '../entity/Attribute';
53
+ import ProductAttribute from '../entity/ProductAttribute';
54
+ import CategoryImages from '../entity/CategoryImages';
52
55
  import { CartItemRepository, CartRepository, CheckoutBillingAddressRepository, CheckoutRepository, CheckoutShippingAddressRepository, PriceDataRepository } from './shopcart';
53
56
  import { ProductShippingRepository, ShippingCountryRepository, ShippingRepository } from './shipping';
54
57
  import { Repository } from 'typeorm';
58
+ export declare class CategoryImagesRepository extends Repository<CategoryImages> {
59
+ }
60
+ export declare class ProductAttributeRepository extends Repository<ProductAttribute> {
61
+ }
62
+ export declare class AttributeRepository extends Repository<Attribute> {
63
+ }
55
64
  export declare class CustomVariantRepository extends Repository<CustomVariant> {
56
65
  }
57
66
  export declare class CustomProductRepository extends Repository<CustomProduct> {
@@ -9,8 +9,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
9
9
  return (mod && mod.__esModule) ? mod : { "default": mod };
10
10
  };
11
11
  Object.defineProperty(exports, "__esModule", { value: true });
12
- exports.CurrencyRepository = exports.UserChannelApiKeyRepository = exports.ChannelUserProductSyncRepository = exports.ChannelUserRepository = exports.ChannelGroupRepository = exports.CollectionSharedRepository = exports.CollectionItemRepository = exports.CollectionRepository = exports.PaymentMethodRepository = exports.UserSettingsRepository = exports.UserTokenWoltRepository = exports.WooConnectionRepository = exports.WalletRepository = exports.VariantRepository = exports.UserRoleRepository = exports.UserRepository = exports.SubcategoryRepository = exports.ShopifyConnectionRepository = exports.ShippingPackageRepository = exports.RolePermissionRepository = exports.RoleRepository = exports.RequestRepository = exports.ProductRepository = exports.PermissionRepository = exports.PaymentShopifyRepository = exports.PaymentRepository = exports.OrderTrackingRepository = exports.OrderShippingRepository = exports.OrderItemRepository = exports.OrderRepository = exports.OptionRepository = exports.NotificationRepository = exports.MetricActiveUserRepository = exports.MagentoConnectionRepository = exports.ImportedProductRepository = exports.ImageRepository = exports.FlatRateCountryRepository = exports.FlatRateRepository = exports.CourierRepository = exports.CountryRepository = exports.CheckoutMetadataRepository = exports.ChannelRepository = exports.CategoryRepository = exports.CardRegistrationRepository = exports.BusinessRepository = exports.BankAccountRepository = exports.ApiCredentialRepository = exports.CustomProductImageRepository = exports.CustomProductRepository = exports.CustomVariantRepository = void 0;
13
- exports.ShippingRepository = exports.ShippingCountryRepository = exports.ProductShippingRepository = exports.PriceDataRepository = exports.CheckoutShippingAddressRepository = exports.CheckoutRepository = exports.CheckoutBillingAddressRepository = exports.CartRepository = exports.CartItemRepository = exports.ExchangeRateRepository = void 0;
12
+ exports.ChannelUserRepository = exports.ChannelGroupRepository = exports.CollectionSharedRepository = exports.CollectionItemRepository = exports.CollectionRepository = exports.PaymentMethodRepository = exports.UserSettingsRepository = exports.UserTokenWoltRepository = exports.WooConnectionRepository = exports.WalletRepository = exports.VariantRepository = exports.UserRoleRepository = exports.UserRepository = exports.SubcategoryRepository = exports.ShopifyConnectionRepository = exports.ShippingPackageRepository = exports.RolePermissionRepository = exports.RoleRepository = exports.RequestRepository = exports.ProductRepository = exports.PermissionRepository = exports.PaymentShopifyRepository = exports.PaymentRepository = exports.OrderTrackingRepository = exports.OrderShippingRepository = exports.OrderItemRepository = exports.OrderRepository = exports.OptionRepository = exports.NotificationRepository = exports.MetricActiveUserRepository = exports.MagentoConnectionRepository = exports.ImportedProductRepository = exports.ImageRepository = exports.FlatRateCountryRepository = exports.FlatRateRepository = exports.CourierRepository = exports.CountryRepository = exports.CheckoutMetadataRepository = exports.ChannelRepository = exports.CategoryRepository = exports.CardRegistrationRepository = exports.BusinessRepository = exports.BankAccountRepository = exports.ApiCredentialRepository = exports.CustomProductImageRepository = exports.CustomProductRepository = exports.CustomVariantRepository = exports.AttributeRepository = exports.ProductAttributeRepository = exports.CategoryImagesRepository = void 0;
13
+ exports.ShippingRepository = exports.ShippingCountryRepository = exports.ProductShippingRepository = exports.PriceDataRepository = exports.CheckoutShippingAddressRepository = exports.CheckoutRepository = exports.CheckoutBillingAddressRepository = exports.CartRepository = exports.CartItemRepository = exports.ExchangeRateRepository = exports.CurrencyRepository = exports.UserChannelApiKeyRepository = exports.ChannelUserProductSyncRepository = void 0;
14
14
  const ApiCredential_1 = __importDefault(require("../entity/ApiCredential"));
15
15
  const BankAccount_1 = __importDefault(require("../entity/BankAccount"));
16
16
  const Business_1 = __importDefault(require("../entity/Business"));
@@ -62,6 +62,9 @@ const ExchangeRate_1 = __importDefault(require("../entity/ExchangeRate"));
62
62
  const CustomVariant_1 = __importDefault(require("../entity/CustomVariant"));
63
63
  const CustomProduct_1 = require("../entity/CustomProduct");
64
64
  const CustomProductImage_1 = __importDefault(require("../entity/CustomProductImage"));
65
+ const Attribute_1 = __importDefault(require("../entity/Attribute"));
66
+ const ProductAttribute_1 = __importDefault(require("../entity/ProductAttribute"));
67
+ const CategoryImages_1 = __importDefault(require("../entity/CategoryImages"));
65
68
  const shopcart_1 = require("./shopcart");
66
69
  Object.defineProperty(exports, "CartItemRepository", { enumerable: true, get: function () { return shopcart_1.CartItemRepository; } });
67
70
  Object.defineProperty(exports, "CartRepository", { enumerable: true, get: function () { return shopcart_1.CartRepository; } });
@@ -74,6 +77,24 @@ Object.defineProperty(exports, "ProductShippingRepository", { enumerable: true,
74
77
  Object.defineProperty(exports, "ShippingCountryRepository", { enumerable: true, get: function () { return shipping_1.ShippingCountryRepository; } });
75
78
  Object.defineProperty(exports, "ShippingRepository", { enumerable: true, get: function () { return shipping_1.ShippingRepository; } });
76
79
  const typeorm_1 = require("typeorm");
80
+ let CategoryImagesRepository = class CategoryImagesRepository extends typeorm_1.Repository {
81
+ };
82
+ CategoryImagesRepository = __decorate([
83
+ typeorm_1.EntityRepository(CategoryImages_1.default)
84
+ ], CategoryImagesRepository);
85
+ exports.CategoryImagesRepository = CategoryImagesRepository;
86
+ let ProductAttributeRepository = class ProductAttributeRepository extends typeorm_1.Repository {
87
+ };
88
+ ProductAttributeRepository = __decorate([
89
+ typeorm_1.EntityRepository(ProductAttribute_1.default)
90
+ ], ProductAttributeRepository);
91
+ exports.ProductAttributeRepository = ProductAttributeRepository;
92
+ let AttributeRepository = class AttributeRepository extends typeorm_1.Repository {
93
+ };
94
+ AttributeRepository = __decorate([
95
+ typeorm_1.EntityRepository(Attribute_1.default)
96
+ ], AttributeRepository);
97
+ exports.AttributeRepository = AttributeRepository;
77
98
  let CustomVariantRepository = class CustomVariantRepository extends typeorm_1.Repository {
78
99
  };
79
100
  CustomVariantRepository = __decorate([
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/repositories/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,4EAAoD;AACpD,wEAAgD;AAChD,kEAA0C;AAC1C,kFAA0D;AAC1D,kEAA0C;AAC1C,gEAAwC;AACxC,kFAA0D;AAC1D,gEAAwC;AACxC,gEAAwC;AACxC,kEAA0C;AAC1C,gFAAwD;AACxD,4DAAoC;AACpC,gFAAwD;AACxD,iFAAuE;AACvE,kFAA0D;AAC1D,0EAAkD;AAClD,8DAAsC;AACtC,4DAAoC;AACpC,oEAA4C;AAC5C,4EAAoD;AACpD,4EAAoD;AACpD,gEAAwC;AACxC,8EAAsD;AACtD,sEAA8C;AAC9C,6DAAmD;AACnD,gEAAwC;AACxC,0DAAkC;AAClC,8EAAsD;AACtD,gFAAwD;AACxD,oFAA4D;AAC5D,wEAAgD;AAChD,0DAAkC;AAClC,kEAA0C;AAC1C,gEAAwC;AACxC,8DAAsC;AACtC,4EAAoD;AACpD,4EAAoD;AACpD,0EAAkD;AAClD,4EAAoD;AACpD,sEAA8C;AAC9C,8EAAsD;AACtD,kFAA0D;AAC1D,0EAAkD;AAClD,wEAAgD;AAChD,8FAAsE;AACtE,oFAA4D;AAC5D,kEAA0C;AAC1C,0EAAkD;AAElD,4EAAoD;AACpD,2DAAwD;AACxD,sFAA8D;AAE9D,yCAOoB;AAoKlB,mGA1KA,6BAAkB,OA0KA;AAClB,+FA1KA,yBAAc,OA0KA;AACd,iHA1KA,2CAAgC,OA0KA;AAChC,mGA1KA,6BAAkB,OA0KA;AAClB,kHA1KA,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AAQ,oBAAkC;CAAG,CAAA;AAA9E,gCAAgC;IAD5C,0BAAgB,CAAC,gCAAsB,CAAC;GAC5B,gCAAgC,CAA8C;AAA9E,4EAAgC;AAG7C,IAAa,2BAA2B,GAAxC,MAAa,2BAA4B,SAAQ,oBAA6B;CAAG,CAAA;AAApE,2BAA2B;IADvC,0BAAgB,CAAC,2BAAiB,CAAC;GACvB,2BAA2B,CAAyC;AAApE,kEAA2B;AAGxC,IAAa,kBAAkB,GAA/B,MAAa,kBAAmB,SAAQ,oBAAoB;CAAG,CAAA;AAAlD,kBAAkB;IAD9B,0BAAgB,CAAC,kBAAQ,CAAC;GACd,kBAAkB,CAAgC;AAAlD,gDAAkB;AAG/B,IAAa,sBAAsB,GAAnC,MAAa,sBAAuB,SAAQ,oBAAwB;CAAG,CAAA;AAA1D,sBAAsB;IADlC,0BAAgB,CAAC,sBAAY,CAAC;GAClB,sBAAsB,CAAoC;AAA1D,wDAAsB"}
@@ -1921,14 +1921,19 @@
1921
1921
  "signature": "7ecfaf1bbfdc6d7a697c4132049105fc3c6ca0972a57f7dd845011d10294ad2b",
1922
1922
  "affectsGlobalScope": false
1923
1923
  },
1924
+ "../src/entity/categoryimages.ts": {
1925
+ "version": "c5866556048c851f9c616bab5c1a40b1f0bb899c87f72f5e3e0b3a8c8940fa49",
1926
+ "signature": "3bba1dcb724720a0a0adaadba003bc6ab47fb41ce4b095a1c6e1974168b15bd7",
1927
+ "affectsGlobalScope": false
1928
+ },
1924
1929
  "../src/entity/subcategory.ts": {
1925
- "version": "73b85383e0bd1ef6ed0a103cc3e247ea0f4507bbdafcaf78b38930c39c61e49b",
1926
- "signature": "7b2670d549ce3013f7fe122e1ee02009ee3b2995a7ba2af385527d2f02329012",
1930
+ "version": "26b02abbae1a4dd83bc9cfb040ad080a6083938f74557045e8e24a7d394ba782",
1931
+ "signature": "6bab357cec0125bbac6b707fb8c841355bedeb0c56fc4684822a90a7ca390fdb",
1927
1932
  "affectsGlobalScope": false
1928
1933
  },
1929
1934
  "../src/entity/category.ts": {
1930
- "version": "9a4dee6903416f8ceabcd21c6b97d16a2edb41c070eacfbe77bd1017a580f6e8",
1931
- "signature": "bb0008e837e170275a056f56f3d1b6e37b5b2c7e5680658cf79afec5cb023fcc",
1935
+ "version": "6c751f3828cd94ca0c58c9eb6233dfd53911c8b724dacc4914831ebbf7e813be",
1936
+ "signature": "d6ddb14959258ec40c16686f1507aefb5ab53fca69c6fba9f12f887cacd4a89b",
1932
1937
  "affectsGlobalScope": false
1933
1938
  },
1934
1939
  "../src/entity/courier.ts": {
@@ -2451,9 +2456,19 @@
2451
2456
  "signature": "2be82cb7b1d51d45793ac845f76e09caf9d61beaf6341095b5dd10a4480c73e2",
2452
2457
  "affectsGlobalScope": false
2453
2458
  },
2459
+ "../src/entity/attribute.ts": {
2460
+ "version": "a9121f448ea5883738db27a9aab8c6a001b11e1a6c06d8bc9261349df04e64f7",
2461
+ "signature": "eb72ead21fda7d0b46b85ec8090ec67349827f28d5e395496ae5e32937269ff9",
2462
+ "affectsGlobalScope": false
2463
+ },
2464
+ "../src/entity/productattribute.ts": {
2465
+ "version": "2387efcbc67e98783730e013f56448c114f6420014bd7d35a407a9304248b065",
2466
+ "signature": "ad4af02efb2513ca7f4195e57e966e7cdd7c36d89081c66eb3c7e429bbd3c027",
2467
+ "affectsGlobalScope": false
2468
+ },
2454
2469
  "../src/entity/product.entity.ts": {
2455
- "version": "e9a0cfa57c08ac22459de639acdb0cb610e6f8a3cee9abf1de91997c46446654",
2456
- "signature": "983e7b198259edcd8ac405f6cb524318b3b617c15d9838f63a7ada5d5003d737",
2470
+ "version": "6cc247b47067da0a3020f8bc3c739841e185248db06e363cab7aea3a42545b2c",
2471
+ "signature": "a9727ab4468763426f159d56e046a2c6946eae96de4e53d98aeab749a5152f76",
2457
2472
  "affectsGlobalScope": false
2458
2473
  },
2459
2474
  "../src/entity/collectionitem.ts": {
@@ -2607,8 +2622,8 @@
2607
2622
  "affectsGlobalScope": false
2608
2623
  },
2609
2624
  "../src/entity/index.ts": {
2610
- "version": "4c58c3b2af6a940332d9941224ecc68d4bb3828d48efe41895a54204ec7c3da8",
2611
- "signature": "1a5fcadb5120bb63cdaf4e791a304fc8e6efdd91a3ccb750abba1fd4e32bda04",
2625
+ "version": "144582c2fc899b1b172056c49b698fa1d904a0c0c241bca68ded469236ead98f",
2626
+ "signature": "c41c2724dee5f5006abbec545a39e37670f3a02b7c049271016b91e2c181f5cb",
2612
2627
  "affectsGlobalScope": false
2613
2628
  },
2614
2629
  "../src/staticdata/productorigin.ts": {
@@ -2677,8 +2692,8 @@
2677
2692
  "affectsGlobalScope": false
2678
2693
  },
2679
2694
  "../src/repositories/index.ts": {
2680
- "version": "9123c913e01c83c57e9cb83de603cb21fc85a2ebcb1ceb9433f2e1ac20a1d14c",
2681
- "signature": "def20383e8a054bcb53ce5c24d5a6975ec721f908071271acce81f4c4af7cdbb",
2695
+ "version": "41ae69bf0100fe747918ed8545f4f23e4732c4c3b6dcd82fc50d15c298ccfff9",
2696
+ "signature": "0f96ae2ba8cc8b0cdc018c24d6fb8798235c281c12e33413d116dadda1e0004f",
2682
2697
  "affectsGlobalScope": false
2683
2698
  },
2684
2699
  "../src/subscribers/productsubscriber.ts": {
@@ -2798,7 +2813,7 @@
2798
2813
  },
2799
2814
  "../src/helpers/products/storage/search.ts": {
2800
2815
  "version": "56182ffa45a3411aaf6498d7b99d2711f01f529a523ec0839f286d1967252fa7",
2801
- "signature": "80f420af0279a48521635580bd75aa2da23dda0666ddadf18d007d7749b8cc67",
2816
+ "signature": "5fa34362b2f18f0df3727649a39c4c1f75d575a7c08c6135d33d3571efd7ceb1",
2802
2817
  "affectsGlobalScope": false
2803
2818
  },
2804
2819
  "../src/helpers/products/storage/index.ts": {
@@ -2981,6 +2996,21 @@
2981
2996
  "signature": "0e5a2728f9688b495318366870eb0f07503b29fab2d3ceb79915e144778ae2ac",
2982
2997
  "affectsGlobalScope": false
2983
2998
  },
2999
+ "../src/migrations/1677706695399-promote_to_production_2023_01_03.ts": {
3000
+ "version": "a71be0c98f088d4bb023f1a0d066bdf806a1cfacb07f3969e14d403c68fbc9d7",
3001
+ "signature": "5c4edd69708ca8a11f2aa55bcf1acfb520678afefba346a893b7697974dbdb8b",
3002
+ "affectsGlobalScope": false
3003
+ },
3004
+ "../src/migrations/1677763068338-task-1032v1.ts": {
3005
+ "version": "6e09e6b6ce6e48e85bffe6b253207cec03a637250e194570e90b18573056c6d1",
3006
+ "signature": "a3a7ebedf800879ffa5e04d45d6a73ac216816a05ad67ab63e6671467950a5cf",
3007
+ "affectsGlobalScope": false
3008
+ },
3009
+ "../src/migrations/1677764464274-task-1032v2.ts": {
3010
+ "version": "9b976a871513072a917fe9486edcb2b1cfe06a00030bee40b4b240502c0a76ef",
3011
+ "signature": "0b0c73764a789c14efda2c2211880a22ecb26f1f57921327745ebb29dd3e317b",
3012
+ "affectsGlobalScope": false
3013
+ },
2984
3014
  "../src/migrations/execute/index.ts": {
2985
3015
  "version": "8b5bf13d095aeb57afd593adf3d799681176a13c327e2f77e0028e178c4ee3b9",
2986
3016
  "signature": "8e609bb71c20b858c77f0e9f90bb1319db8477b13f9f965f1a1e18524bf50881",
@@ -4917,6 +4947,11 @@
4917
4947
  "../src/entity/auditedmodel.ts",
4918
4948
  "../src/entity/user.ts"
4919
4949
  ],
4950
+ "../src/entity/attribute.ts": [
4951
+ "../node_modules/typeorm/index.d.ts",
4952
+ "../src/entity/auditedmodel.ts",
4953
+ "../src/entity/productattribute.ts"
4954
+ ],
4920
4955
  "../src/entity/auditedmodel.ts": [
4921
4956
  "../node_modules/typeorm/index.d.ts"
4922
4957
  ],
@@ -4941,8 +4976,15 @@
4941
4976
  ],
4942
4977
  "../src/entity/category.ts": [
4943
4978
  "../node_modules/typeorm/index.d.ts",
4979
+ "../src/entity/auditedmodel.ts",
4980
+ "../src/entity/categoryimages.ts",
4944
4981
  "../src/entity/subcategory.ts"
4945
4982
  ],
4983
+ "../src/entity/categoryimages.ts": [
4984
+ "../node_modules/typeorm/index.d.ts",
4985
+ "../src/entity/auditedmodel.ts",
4986
+ "../src/entity/category.ts"
4987
+ ],
4946
4988
  "../src/entity/channel.ts": [
4947
4989
  "../node_modules/typeorm/index.d.ts",
4948
4990
  "../src/entity/auditedmodel.ts",
@@ -5070,12 +5112,14 @@
5070
5112
  "../src/entity/index.ts": [
5071
5113
  "../src/entity/address.ts",
5072
5114
  "../src/entity/apicredential.ts",
5115
+ "../src/entity/attribute.ts",
5073
5116
  "../src/entity/auditedmodel.ts",
5074
5117
  "../src/entity/bankaccount.ts",
5075
5118
  "../src/entity/business.ts",
5076
5119
  "../src/entity/businessproducts.ts",
5077
5120
  "../src/entity/cardregistration.ts",
5078
5121
  "../src/entity/category.ts",
5122
+ "../src/entity/categoryimages.ts",
5079
5123
  "../src/entity/channel.ts",
5080
5124
  "../src/entity/channelgroup.ts",
5081
5125
  "../src/entity/channeluser.ts",
@@ -5122,6 +5166,7 @@
5122
5166
  "../src/entity/permission.ts",
5123
5167
  "../src/entity/price.entity.ts",
5124
5168
  "../src/entity/product.entity.ts",
5169
+ "../src/entity/productattribute.ts",
5125
5170
  "../src/entity/request.ts",
5126
5171
  "../src/entity/return.ts",
5127
5172
  "../src/entity/returnaddress.ts",
@@ -5272,11 +5317,18 @@
5272
5317
  "../src/entity/modules/shipping/productshipping.ts",
5273
5318
  "../src/entity/option.ts",
5274
5319
  "../src/entity/price.entity.ts",
5320
+ "../src/entity/productattribute.ts",
5275
5321
  "../src/entity/subcategory.ts",
5276
5322
  "../src/entity/user.ts",
5277
5323
  "../src/entity/variant.ts",
5278
5324
  "../src/staticdata/currency.ts"
5279
5325
  ],
5326
+ "../src/entity/productattribute.ts": [
5327
+ "../node_modules/typeorm/index.d.ts",
5328
+ "../src/entity/attribute.ts",
5329
+ "../src/entity/auditedmodel.ts",
5330
+ "../src/entity/product.entity.ts"
5331
+ ],
5280
5332
  "../src/entity/request.ts": [
5281
5333
  "../node_modules/typeorm/index.d.ts",
5282
5334
  "../src/entity/auditedmodel.ts",
@@ -5307,6 +5359,7 @@
5307
5359
  ],
5308
5360
  "../src/entity/subcategory.ts": [
5309
5361
  "../node_modules/typeorm/index.d.ts",
5362
+ "../src/entity/auditedmodel.ts",
5310
5363
  "../src/entity/category.ts"
5311
5364
  ],
5312
5365
  "../src/entity/user.ts": [
@@ -5538,6 +5591,15 @@
5538
5591
  "../src/migrations/1676656657956-task-1084v1.ts": [
5539
5592
  "../node_modules/typeorm/index.d.ts"
5540
5593
  ],
5594
+ "../src/migrations/1677706695399-promote_to_production_2023_01_03.ts": [
5595
+ "../node_modules/typeorm/index.d.ts"
5596
+ ],
5597
+ "../src/migrations/1677763068338-task-1032v1.ts": [
5598
+ "../node_modules/typeorm/index.d.ts"
5599
+ ],
5600
+ "../src/migrations/1677764464274-task-1032v2.ts": [
5601
+ "../node_modules/typeorm/index.d.ts"
5602
+ ],
5541
5603
  "../src/migrations/execute/index.ts": [
5542
5604
  "../src/config/connect.ts"
5543
5605
  ],
@@ -5556,10 +5618,12 @@
5556
5618
  "../src/repositories/index.ts": [
5557
5619
  "../node_modules/typeorm/index.d.ts",
5558
5620
  "../src/entity/apicredential.ts",
5621
+ "../src/entity/attribute.ts",
5559
5622
  "../src/entity/bankaccount.ts",
5560
5623
  "../src/entity/business.ts",
5561
5624
  "../src/entity/cardregistration.ts",
5562
5625
  "../src/entity/category.ts",
5626
+ "../src/entity/categoryimages.ts",
5563
5627
  "../src/entity/channel.ts",
5564
5628
  "../src/entity/channelgroup.ts",
5565
5629
  "../src/entity/channeluser.ts",
@@ -5592,6 +5656,7 @@
5592
5656
  "../src/entity/paymentshopify.ts",
5593
5657
  "../src/entity/permission.ts",
5594
5658
  "../src/entity/product.entity.ts",
5659
+ "../src/entity/productattribute.ts",
5595
5660
  "../src/entity/request.ts",
5596
5661
  "../src/entity/role.ts",
5597
5662
  "../src/entity/rolepermission.ts",
@@ -7446,6 +7511,10 @@
7446
7511
  "../src/entity/auditedmodel.ts",
7447
7512
  "../src/entity/user.ts"
7448
7513
  ],
7514
+ "../src/entity/attribute.ts": [
7515
+ "../src/entity/auditedmodel.ts",
7516
+ "../src/entity/productattribute.ts"
7517
+ ],
7449
7518
  "../src/entity/bankaccount.ts": [
7450
7519
  "../src/entity/auditedmodel.ts"
7451
7520
  ],
@@ -7460,8 +7529,14 @@
7460
7529
  "../src/entity/auditedmodel.ts"
7461
7530
  ],
7462
7531
  "../src/entity/category.ts": [
7532
+ "../src/entity/auditedmodel.ts",
7533
+ "../src/entity/categoryimages.ts",
7463
7534
  "../src/entity/subcategory.ts"
7464
7535
  ],
7536
+ "../src/entity/categoryimages.ts": [
7537
+ "../src/entity/auditedmodel.ts",
7538
+ "../src/entity/category.ts"
7539
+ ],
7465
7540
  "../src/entity/channel.ts": [
7466
7541
  "../src/entity/auditedmodel.ts",
7467
7542
  "../src/entity/channeluser.ts",
@@ -7547,12 +7622,14 @@
7547
7622
  "../src/entity/index.ts": [
7548
7623
  "../src/entity/address.ts",
7549
7624
  "../src/entity/apicredential.ts",
7625
+ "../src/entity/attribute.ts",
7550
7626
  "../src/entity/auditedmodel.ts",
7551
7627
  "../src/entity/bankaccount.ts",
7552
7628
  "../src/entity/business.ts",
7553
7629
  "../src/entity/businessproducts.ts",
7554
7630
  "../src/entity/cardregistration.ts",
7555
7631
  "../src/entity/category.ts",
7632
+ "../src/entity/categoryimages.ts",
7556
7633
  "../src/entity/channel.ts",
7557
7634
  "../src/entity/channelgroup.ts",
7558
7635
  "../src/entity/channeluser.ts",
@@ -7599,6 +7676,7 @@
7599
7676
  "../src/entity/permission.ts",
7600
7677
  "../src/entity/price.entity.ts",
7601
7678
  "../src/entity/product.entity.ts",
7679
+ "../src/entity/productattribute.ts",
7602
7680
  "../src/entity/request.ts",
7603
7681
  "../src/entity/return.ts",
7604
7682
  "../src/entity/returnaddress.ts",
@@ -7716,10 +7794,16 @@
7716
7794
  "../src/entity/modules/shipping/productshipping.ts",
7717
7795
  "../src/entity/option.ts",
7718
7796
  "../src/entity/price.entity.ts",
7797
+ "../src/entity/productattribute.ts",
7719
7798
  "../src/entity/subcategory.ts",
7720
7799
  "../src/entity/user.ts",
7721
7800
  "../src/entity/variant.ts"
7722
7801
  ],
7802
+ "../src/entity/productattribute.ts": [
7803
+ "../src/entity/attribute.ts",
7804
+ "../src/entity/auditedmodel.ts",
7805
+ "../src/entity/product.entity.ts"
7806
+ ],
7723
7807
  "../src/entity/request.ts": [
7724
7808
  "../src/entity/auditedmodel.ts",
7725
7809
  "../src/entity/user.ts"
@@ -7738,6 +7822,7 @@
7738
7822
  "../src/entity/user.ts"
7739
7823
  ],
7740
7824
  "../src/entity/subcategory.ts": [
7825
+ "../src/entity/auditedmodel.ts",
7741
7826
  "../src/entity/category.ts"
7742
7827
  ],
7743
7828
  "../src/entity/user.ts": [
@@ -7943,6 +8028,15 @@
7943
8028
  "../src/migrations/1676656657956-task-1084v1.ts": [
7944
8029
  "../node_modules/typeorm/index.d.ts"
7945
8030
  ],
8031
+ "../src/migrations/1677706695399-promote_to_production_2023_01_03.ts": [
8032
+ "../node_modules/typeorm/index.d.ts"
8033
+ ],
8034
+ "../src/migrations/1677763068338-task-1032v1.ts": [
8035
+ "../node_modules/typeorm/index.d.ts"
8036
+ ],
8037
+ "../src/migrations/1677764464274-task-1032v2.ts": [
8038
+ "../node_modules/typeorm/index.d.ts"
8039
+ ],
7946
8040
  "../src/migrations/index.ts": [
7947
8041
  "../src/migrations/1628474597284-initialschema.ts",
7948
8042
  "../src/migrations/1630077596132-removemangopay.ts",
@@ -7958,10 +8052,12 @@
7958
8052
  "../src/repositories/index.ts": [
7959
8053
  "../node_modules/typeorm/index.d.ts",
7960
8054
  "../src/entity/apicredential.ts",
8055
+ "../src/entity/attribute.ts",
7961
8056
  "../src/entity/bankaccount.ts",
7962
8057
  "../src/entity/business.ts",
7963
8058
  "../src/entity/cardregistration.ts",
7964
8059
  "../src/entity/category.ts",
8060
+ "../src/entity/categoryimages.ts",
7965
8061
  "../src/entity/channel.ts",
7966
8062
  "../src/entity/channelgroup.ts",
7967
8063
  "../src/entity/channeluser.ts",
@@ -7994,6 +8090,7 @@
7994
8090
  "../src/entity/paymentshopify.ts",
7995
8091
  "../src/entity/permission.ts",
7996
8092
  "../src/entity/product.entity.ts",
8093
+ "../src/entity/productattribute.ts",
7997
8094
  "../src/entity/request.ts",
7998
8095
  "../src/entity/role.ts",
7999
8096
  "../src/entity/rolepermission.ts",
@@ -8537,12 +8634,14 @@
8537
8634
  "../src/config/connect.ts",
8538
8635
  "../src/entity/address.ts",
8539
8636
  "../src/entity/apicredential.ts",
8637
+ "../src/entity/attribute.ts",
8540
8638
  "../src/entity/auditedmodel.ts",
8541
8639
  "../src/entity/bankaccount.ts",
8542
8640
  "../src/entity/business.ts",
8543
8641
  "../src/entity/businessproducts.ts",
8544
8642
  "../src/entity/cardregistration.ts",
8545
8643
  "../src/entity/category.ts",
8644
+ "../src/entity/categoryimages.ts",
8546
8645
  "../src/entity/channel.ts",
8547
8646
  "../src/entity/channelgroup.ts",
8548
8647
  "../src/entity/channeluser.ts",
@@ -8590,6 +8689,7 @@
8590
8689
  "../src/entity/permission.ts",
8591
8690
  "../src/entity/price.entity.ts",
8592
8691
  "../src/entity/product.entity.ts",
8692
+ "../src/entity/productattribute.ts",
8593
8693
  "../src/entity/request.ts",
8594
8694
  "../src/entity/return.ts",
8595
8695
  "../src/entity/returnaddress.ts",
@@ -8657,6 +8757,9 @@
8657
8757
  "../src/migrations/1676389900564-task-1062v4.ts",
8658
8758
  "../src/migrations/1676558804200-task-1074v1.ts",
8659
8759
  "../src/migrations/1676656657956-task-1084v1.ts",
8760
+ "../src/migrations/1677706695399-promote_to_production_2023_01_03.ts",
8761
+ "../src/migrations/1677763068338-task-1032v1.ts",
8762
+ "../src/migrations/1677764464274-task-1032v2.ts",
8660
8763
  "../src/migrations/execute/index.ts",
8661
8764
  "../src/migrations/index.ts",
8662
8765
  "../src/repositories/index.ts",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@reachu/database",
3
- "version": "1.0.1",
3
+ "version": "1.0.3",
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.1",
25
- "@reachu/utils": "1.0.1",
24
+ "@reachu/logger": "1.0.3",
25
+ "@reachu/utils": "1.0.3",
26
26
  "dotenv": "8.0.0",
27
27
  "express": "4.17.1",
28
28
  "mysql2": "1.5.2",
@@ -0,0 +1,30 @@
1
+ import {
2
+ Entity,
3
+ PrimaryGeneratedColumn,
4
+ Column,
5
+ DeleteDateColumn,
6
+ OneToMany,
7
+ JoinColumn,
8
+ } from 'typeorm';
9
+ import AuditedModel from './AuditedModel';
10
+ import ProductAttribute from './ProductAttribute';
11
+
12
+ @Entity()
13
+ export default class Attribute extends AuditedModel {
14
+ @PrimaryGeneratedColumn()
15
+ id: number;
16
+
17
+ @DeleteDateColumn()
18
+ deletedAt: Date;
19
+
20
+ @Column('varchar', { nullable: false })
21
+ name: string;
22
+
23
+ @OneToMany(
24
+ () => ProductAttribute,
25
+ (productAttribute: ProductAttribute) => productAttribute.attribute,
26
+ { cascade: true },
27
+ )
28
+ @JoinColumn()
29
+ productAttribute: ProductAttribute[];
30
+ }
@@ -1,8 +1,18 @@
1
- import { Entity, PrimaryGeneratedColumn, Column, OneToMany } from 'typeorm';
1
+ import {
2
+ Entity,
3
+ PrimaryGeneratedColumn,
4
+ Column,
5
+ OneToMany,
6
+ DeleteDateColumn,
7
+ ManyToOne,
8
+ JoinColumn,
9
+ } from 'typeorm';
10
+ import AuditedModel from './AuditedModel';
11
+ import CategoryImages from './CategoryImages';
2
12
  import Subcategory from './Subcategory';
3
13
 
4
14
  @Entity()
5
- export default class Category {
15
+ export default class Category extends AuditedModel {
6
16
  @PrimaryGeneratedColumn()
7
17
  id: number;
8
18
 
@@ -12,5 +22,21 @@ export default class Category {
12
22
  @OneToMany(() => Subcategory, (subcategory) => subcategory.category)
13
23
  subcategories: Subcategory[];
14
24
 
25
+ @DeleteDateColumn()
26
+ deletedAt: Date;
27
+
28
+ @Column('varchar', { nullable: true })
29
+ slug: string;
30
+
31
+ @Column('integer', { nullable: true })
32
+ menuOrder: number;
33
+
34
+ @ManyToOne(() => CategoryImages, (categoryImages: CategoryImages) => categoryImages.category, {
35
+ eager: true,
36
+ onDelete: 'CASCADE',
37
+ })
38
+ @JoinColumn()
39
+ categoryImages: CategoryImages;
40
+
15
41
  static getCacheKey = () => 'CATEGORIES';
16
42
  }
@@ -0,0 +1,38 @@
1
+ import {
2
+ Entity,
3
+ PrimaryGeneratedColumn,
4
+ Column,
5
+ OneToMany,
6
+ DeleteDateColumn,
7
+ JoinColumn,
8
+ } from 'typeorm';
9
+ import AuditedModel from './AuditedModel';
10
+ import Category from './Category';
11
+
12
+ @Entity()
13
+ export default class CategoryImages extends AuditedModel {
14
+ @PrimaryGeneratedColumn()
15
+ id: number;
16
+
17
+ @DeleteDateColumn()
18
+ deletedAt: Date;
19
+
20
+ @Column('varchar', { nullable: true })
21
+ srcn: string;
22
+
23
+ @Column('varchar', { nullable: true })
24
+ slug: string;
25
+
26
+ @Column('varchar', { nullable: true })
27
+ name: string;
28
+
29
+ @Column('varchar', { nullable: true })
30
+ src: string;
31
+
32
+ @Column('varchar', { nullable: true })
33
+ alt: string;
34
+
35
+ @OneToMany(() => Category, (category: Category) => category.categoryImages, { cascade: true })
36
+ @JoinColumn()
37
+ category: Category[];
38
+ }
@@ -26,6 +26,7 @@ import { currencies } from '../staticData/Currency';
26
26
  import { Price } from './Price.entity';
27
27
  import ProductShipping from './modules/shipping/ProductShipping';
28
28
  import { CustomProduct } from './CustomProduct';
29
+ import ProductAttribute from './ProductAttribute';
29
30
 
30
31
  @Entity()
31
32
  export class Product extends AuditedModel {
@@ -169,6 +170,14 @@ export class Product extends AuditedModel {
169
170
  @JoinColumn()
170
171
  customProduct: CustomProduct;
171
172
 
173
+ @OneToMany(
174
+ () => ProductAttribute,
175
+ (productAttribute: ProductAttribute) => productAttribute.product,
176
+ { cascade: true },
177
+ )
178
+ @JoinColumn()
179
+ productAttribute: ProductAttribute[];
180
+
172
181
  @AfterLoad()
173
182
  convertNumerics() {
174
183
  const diff = (this.referralFee * this.publicPrice) / 100;
@@ -0,0 +1,27 @@
1
+ import { Entity, PrimaryGeneratedColumn, DeleteDateColumn, ManyToOne, JoinColumn } from 'typeorm';
2
+ import Attribute from './Attribute';
3
+ import AuditedModel from './AuditedModel';
4
+ import { Product } from './Product.entity';
5
+
6
+ @Entity()
7
+ export default class ProductAttribute extends AuditedModel {
8
+ @PrimaryGeneratedColumn()
9
+ id: number;
10
+
11
+ @DeleteDateColumn()
12
+ deletedAt: Date;
13
+
14
+ @ManyToOne(() => Attribute, (attribute: Attribute) => attribute.productAttribute, {
15
+ eager: true,
16
+ onDelete: 'CASCADE',
17
+ })
18
+ @JoinColumn()
19
+ attribute: Attribute;
20
+
21
+ @ManyToOne(() => Product, (product: Product) => product.productAttribute, {
22
+ eager: true,
23
+ onDelete: 'CASCADE',
24
+ })
25
+ @JoinColumn()
26
+ product: Product;
27
+ }