rerobe-js-orm 3.7.7 → 3.7.8

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.
@@ -12,6 +12,25 @@ export default class Product extends Base {
12
12
  toProductInputObjForShopifyV2(locationId: string, weightUnit?: string): any[];
13
13
  toObjForTextTranslation(): TranslatableAttributes;
14
14
  toObjForTypesense(): TypesenseProductObj;
15
+ buildUpdatedFieldsForSalesChannel(): {
16
+ title: string;
17
+ description: string;
18
+ price: string;
19
+ gender: string;
20
+ productCategory: string;
21
+ productType: string;
22
+ productStyle: string[];
23
+ brand: string;
24
+ color: string;
25
+ size: string;
26
+ materialComposition: MaterialComposition;
27
+ salePrice: string;
28
+ isOnSale: string;
29
+ discountType: string;
30
+ discountValue: string;
31
+ selectedForClearance: string;
32
+ status: string;
33
+ };
15
34
  updateSelfFromTranslatedTextArray(translatedTextArray?: string[]): void;
16
35
  autoCreateTitle(): string;
17
36
  autoCreateMetaDataTitle(): string;
@@ -380,6 +380,27 @@ class Product extends Base_1.default {
380
380
  });
381
381
  return stagedObj;
382
382
  }
383
+ buildUpdatedFieldsForSalesChannel() {
384
+ return {
385
+ title: this.attributes.title,
386
+ description: this.attributes.description,
387
+ price: this.attributes.price,
388
+ gender: this.filterAttributes.gender,
389
+ productCategory: this.filterAttributes.productCategory,
390
+ productType: this.filterAttributes.productType,
391
+ productStyle: this.filterAttributes.productStyle,
392
+ brand: this.filterAttributes.brand,
393
+ color: this.filterAttributes.color,
394
+ size: this.filterAttributes.size,
395
+ materialComposition: this.filterAttributes.materialComposition,
396
+ salePrice: this.consignmentAttributes.salePrice,
397
+ isOnSale: this.consignmentAttributes.isOnSale,
398
+ discountType: this.consignmentAttributes.discountType,
399
+ discountValue: this.consignmentAttributes.discountValue,
400
+ selectedForClearance: this.consignmentAttributes.selectedForClearance,
401
+ status: this.consignmentAttributes.status,
402
+ };
403
+ }
383
404
  updateSelfFromTranslatedTextArray(translatedTextArray = []) {
384
405
  const checkFieldTranslated = (val) => {
385
406
  return val !== this.FIELD_NOT_TRANSLATABLE_KEY;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "rerobe-js-orm",
3
- "version": "3.7.7",
3
+ "version": "3.7.8",
4
4
  "description": "ReRobe's Javascript ORM Framework",
5
5
  "main": "lib/index.js",
6
6
  "types": "lib/index.d.ts",