@infrab4a/connect 4.0.0-beta.42 → 4.0.0-beta.43

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.
@@ -1202,21 +1202,27 @@ class Filter extends BaseModel {
1202
1202
  }
1203
1203
  }
1204
1204
 
1205
- class KitProduct extends BaseModel {
1205
+ class CategoryBase extends BaseModel {
1206
1206
  static get identifiersFields() {
1207
- return ['productId', 'kitProductId'];
1207
+ return ['id'];
1208
1208
  }
1209
1209
  }
1210
1210
  __decorate([
1211
- Type(() => Product),
1212
- __metadata("design:type", Product)
1213
- ], KitProduct.prototype, "kit", void 0);
1211
+ Type(() => CategoryBase),
1212
+ __metadata("design:type", CategoryBase)
1213
+ ], CategoryBase.prototype, "parent", void 0);
1214
1214
  __decorate([
1215
- Type(() => Product),
1216
- __metadata("design:type", Product)
1217
- ], KitProduct.prototype, "product", void 0);
1215
+ Type(() => Filter),
1216
+ __metadata("design:type", Array)
1217
+ ], CategoryBase.prototype, "filters", void 0);
1218
1218
 
1219
- class Product extends BaseModel {
1219
+ class CategoryForProduct extends CategoryBase {
1220
+ static get identifiersFields() {
1221
+ return ['id'];
1222
+ }
1223
+ }
1224
+
1225
+ class ProductBase extends BaseModel {
1220
1226
  get evaluation() {
1221
1227
  return {
1222
1228
  reviews: this.reviews,
@@ -1239,30 +1245,48 @@ class Product extends BaseModel {
1239
1245
  return ['id'];
1240
1246
  }
1241
1247
  }
1248
+
1249
+ class ProductForKit extends ProductBase {
1250
+ static get identifiersFields() {
1251
+ return ['id'];
1252
+ }
1253
+ }
1242
1254
  __decorate([
1243
- Type(() => Category),
1244
- __metadata("design:type", Category)
1245
- ], Product.prototype, "category", void 0);
1255
+ Type(() => CategoryForProduct),
1256
+ __metadata("design:type", CategoryForProduct)
1257
+ ], ProductForKit.prototype, "category", void 0);
1258
+
1259
+ class KitProduct extends BaseModel {
1260
+ static get identifiersFields() {
1261
+ return ['productId', 'kitProductId'];
1262
+ }
1263
+ }
1246
1264
  __decorate([
1247
- Type(() => KitProduct),
1248
- __metadata("design:type", Array)
1249
- ], Product.prototype, "kitProducts", void 0);
1265
+ Type(() => ProductForKit),
1266
+ __metadata("design:type", ProductForKit)
1267
+ ], KitProduct.prototype, "kit", void 0);
1268
+ __decorate([
1269
+ Type(() => ProductForKit),
1270
+ __metadata("design:type", ProductForKit)
1271
+ ], KitProduct.prototype, "product", void 0);
1250
1272
 
1251
- class Category extends BaseModel {
1273
+ class ProductForCategory extends ProductBase {
1252
1274
  static get identifiersFields() {
1253
1275
  return ['id'];
1254
1276
  }
1255
1277
  }
1256
1278
  __decorate([
1257
- Type(() => Category),
1258
- __metadata("design:type", Category)
1259
- ], Category.prototype, "parent", void 0);
1260
- __decorate([
1261
- Type(() => Filter),
1279
+ Type(() => KitProduct),
1262
1280
  __metadata("design:type", Array)
1263
- ], Category.prototype, "filters", void 0);
1281
+ ], ProductForCategory.prototype, "kitProducts", void 0);
1282
+
1283
+ class Category extends CategoryBase {
1284
+ static get identifiersFields() {
1285
+ return ['id'];
1286
+ }
1287
+ }
1264
1288
  __decorate([
1265
- Type(() => Product),
1289
+ Type(() => ProductForCategory),
1266
1290
  __metadata("design:type", Array)
1267
1291
  ], Category.prototype, "childrenProducts", void 0);
1268
1292
 
@@ -1311,6 +1335,20 @@ class FilterOption extends BaseModel {
1311
1335
  }
1312
1336
  }
1313
1337
 
1338
+ class Product extends ProductBase {
1339
+ static get identifiersFields() {
1340
+ return ['id'];
1341
+ }
1342
+ }
1343
+ __decorate([
1344
+ Type(() => CategoryForProduct),
1345
+ __metadata("design:type", CategoryForProduct)
1346
+ ], Product.prototype, "category", void 0);
1347
+ __decorate([
1348
+ Type(() => KitProduct),
1349
+ __metadata("design:type", Array)
1350
+ ], Product.prototype, "kitProducts", void 0);
1351
+
1314
1352
  class Variant extends BaseModel {
1315
1353
  static get identifiersFields() {
1316
1354
  return ['id', 'productId'];