@nuskin/ns-product-lib 2.5.0-cx24-2179.2.4 → 2.5.0-cx24-2179.2.5
Sign up to get free protection for your applications and to get access to all the features.
- package/CHANGELOG.md +7 -0
- package/package.json +1 -1
- package/src/product.js +4 -4
package/CHANGELOG.md
CHANGED
@@ -1,3 +1,10 @@
|
|
1
|
+
# [2.5.0-cx24-2179.2.5](https://code.tls.nuskin.io/ns-am/product/js-libs/ns-product-lib/compare/v2.5.0-cx24-2179.2.4...v2.5.0-cx24-2179.2.5) (2022-12-05)
|
2
|
+
|
3
|
+
|
4
|
+
### New
|
5
|
+
|
6
|
+
* added eq promoion bypass for setPriceAndPvFromType v3 (#CX24-2179) ([79fe156](https://code.tls.nuskin.io/ns-am/product/js-libs/ns-product-lib/commit/79fe1562d0cafc44f8945e57c316c8ba0b55a88b)), closes [#CX24-2179](https://code.tls.nuskin.io/ns-am/product/js-libs/ns-product-lib/issues/CX24-2179)
|
7
|
+
|
1
8
|
# [2.5.0-cx24-2179.2.4](https://code.tls.nuskin.io/ns-am/product/js-libs/ns-product-lib/compare/v2.5.0-cx24-2179.2.3...v2.5.0-cx24-2179.2.4) (2022-12-05)
|
2
9
|
|
3
10
|
|
package/package.json
CHANGED
package/src/product.js
CHANGED
@@ -250,7 +250,6 @@ const Product = function(productData) {
|
|
250
250
|
|
251
251
|
if (option.isEqPromotion) {
|
252
252
|
//retain product.price as original price
|
253
|
-
this.setPrice(eventPricing.price || this.getPricing(priceType));
|
254
253
|
this.setCv(this.getCvWithType(priceType));
|
255
254
|
this.setPv(this.getPvWithType(priceType));
|
256
255
|
this.priceType = priceType;
|
@@ -261,7 +260,8 @@ const Product = function(productData) {
|
|
261
260
|
if (
|
262
261
|
this.variants[variantSku].setPriceAndPvFromType(
|
263
262
|
priceType,
|
264
|
-
_activeEvents
|
263
|
+
_activeEvents,
|
264
|
+
option
|
265
265
|
)
|
266
266
|
) {
|
267
267
|
changed = true;
|
@@ -291,7 +291,7 @@ const Product = function(productData) {
|
|
291
291
|
this.priceMap[type] = price;
|
292
292
|
};
|
293
293
|
|
294
|
-
this.addPricingFromStatus = function(productStatus, priceType) {
|
294
|
+
this.addPricingFromStatus = function(productStatus, priceType, option ={}) {
|
295
295
|
let modified = false;
|
296
296
|
|
297
297
|
if (!priceType) {
|
@@ -329,7 +329,7 @@ const Product = function(productData) {
|
|
329
329
|
if(productStatus.childSkus) {
|
330
330
|
this.childSkus = productStatus.childSkus;
|
331
331
|
}
|
332
|
-
this.setPriceAndPvFromType(priceType);
|
332
|
+
this.setPriceAndPvFromType(priceType, null, option);
|
333
333
|
modified = true;
|
334
334
|
} else {
|
335
335
|
let variant = this.getVariant(productStatusSku);
|