@nuskin/product-components 3.17.11-brw-4218.1 → 3.17.11
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/.releaserc +1 -1
- package/docs/CHANGELOG.md +1 -1
- package/gl-sbom-npm-yarn.cdx.json +2 -2
- package/mixins/NsProductMixin.js +8 -30
- package/package.json +2 -2
package/.releaserc
CHANGED
package/docs/CHANGELOG.md
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
## [3.17.11
|
|
1
|
+
## [3.17.11](https://code.tls.nuskin.io/ns-am/ux/product-components/compare/v3.17.10...v3.17.11) (2024-08-22)
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"bomFormat": "CycloneDX",
|
|
3
3
|
"specVersion": "1.4",
|
|
4
|
-
"serialNumber": "urn:uuid:
|
|
4
|
+
"serialNumber": "urn:uuid:9cc5144a-9548-4485-b27b-466c1afa6324",
|
|
5
5
|
"version": 1,
|
|
6
6
|
"metadata": {
|
|
7
|
-
"timestamp": "2024-08-
|
|
7
|
+
"timestamp": "2024-08-22T19:37:18Z",
|
|
8
8
|
"tools": [
|
|
9
9
|
{
|
|
10
10
|
"vendor": "GitLab",
|
package/mixins/NsProductMixin.js
CHANGED
|
@@ -822,22 +822,8 @@ const NsProductMixin = {
|
|
|
822
822
|
* Set product pricing
|
|
823
823
|
*/
|
|
824
824
|
setStandardPricing() {
|
|
825
|
-
const equinoxMarketsConfig = getCachedConfiguration("Equinox_Markets");
|
|
826
|
-
const isGraphQLActive = equinoxMarketsConfig.MySite_graphql_active;
|
|
827
|
-
|
|
828
825
|
// set price and points
|
|
829
826
|
this.originalPrice = this.product.getPricing(PriceType.WRTL);
|
|
830
|
-
|
|
831
|
-
//graphQL adjustments
|
|
832
|
-
if (isGraphQLActive) {
|
|
833
|
-
this.originalPrice =
|
|
834
|
-
this.product.childSkus &&
|
|
835
|
-
this.product.childSkus.length &&
|
|
836
|
-
this.getPriceType() === PriceType.WWHL
|
|
837
|
-
? this.product.getPricing(PriceType.WHL)
|
|
838
|
-
: this.product.getPricing(PriceType.RTL);
|
|
839
|
-
}
|
|
840
|
-
|
|
841
827
|
this.priceType = this.getPriceType();
|
|
842
828
|
this.price = this.product.getPricing(this.priceType);
|
|
843
829
|
this.points = this.product.getPvFixed();
|
|
@@ -889,23 +875,15 @@ const NsProductMixin = {
|
|
|
889
875
|
// set sales event pricing and points
|
|
890
876
|
this.originalPriceType = this.product.priceType;
|
|
891
877
|
|
|
892
|
-
this.originalPrice = isGraphQLActive
|
|
893
|
-
? this.product.getPricing(PriceType.WRTL)
|
|
894
|
-
: this.product.getOriginalPrice();
|
|
895
|
-
|
|
896
|
-
//workaround for graphQL active to show original price
|
|
897
878
|
if (isGraphQLActive) {
|
|
898
|
-
this.originalPrice =
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
? this.product.getPricing(PriceType.WHL)
|
|
903
|
-
: this.product.getPricing(PriceType.RTL);
|
|
879
|
+
this.originalPrice = this.product.getPricing(this.originalPriceType);
|
|
880
|
+
this.product.priceType = `${this.eventName}-${this.originalPriceType}`;
|
|
881
|
+
} else {
|
|
882
|
+
this.product.getOriginalPrice();
|
|
904
883
|
}
|
|
905
884
|
|
|
906
885
|
this.priceType = this.product.priceType;
|
|
907
|
-
|
|
908
|
-
this.price = this.product.getPrice();
|
|
886
|
+
this.price = this.product.getPricing(this.priceType);
|
|
909
887
|
|
|
910
888
|
//If EQ market, always show the discounted price if product has promotion
|
|
911
889
|
//Hence, we set the price to member(wholesale / PriceType.WADW) if the price type PriceType.WADR (retail)
|
|
@@ -919,9 +897,9 @@ const NsProductMixin = {
|
|
|
919
897
|
//for product that has promotion
|
|
920
898
|
//set the price to WWHL if this.getPriceType() === WRTL
|
|
921
899
|
//promotion price is set in product.js setPriceAndPvFromType function
|
|
922
|
-
if (isGraphQLActive && this.getPriceType() == PriceType.WRTL) {
|
|
923
|
-
|
|
924
|
-
}
|
|
900
|
+
// if (isGraphQLActive && this.getPriceType() == PriceType.WRTL) {
|
|
901
|
+
// this.price = this.product.getPricing(PriceType.WWHL);
|
|
902
|
+
// }
|
|
925
903
|
|
|
926
904
|
if (this.user && this.isDistributor) {
|
|
927
905
|
this.points = this.product.getPvFixed();
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nuskin/product-components",
|
|
3
|
-
"version": "3.17.11
|
|
3
|
+
"version": "3.17.11",
|
|
4
4
|
"description": "Nu Skin Product Components",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"scripts": {
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
"@nuskin/ns-core-styles": "2.11.2",
|
|
30
30
|
"@nuskin/ns-icon": "^2.12.0",
|
|
31
31
|
"@nuskin/ns-loyalty-web": "1.5.6",
|
|
32
|
-
"@nuskin/ns-product-lib": "2.
|
|
32
|
+
"@nuskin/ns-product-lib": "2.19.0",
|
|
33
33
|
"@nuskin/ns-shop": "7.0.8",
|
|
34
34
|
"@nuskin/product-recommendation": "2.0.1",
|
|
35
35
|
"axios": "1.6.7",
|