@pisell/pisellos 0.0.415 → 0.0.416
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.
|
@@ -159,7 +159,7 @@ export var RulesModule = /*#__PURE__*/function (_BaseModule) {
|
|
|
159
159
|
var filteredOldDiscountList = oldDiscountList.filter(function (discount) {
|
|
160
160
|
return !discount.isEditMode && (discount.tag !== 'good_pass' || discount.isScan);
|
|
161
161
|
});
|
|
162
|
-
var mergedDiscountList = uniqueById(
|
|
162
|
+
var mergedDiscountList = uniqueById([].concat(_toConsumableArray(filteredOldDiscountList), _toConsumableArray(newDiscountList)));
|
|
163
163
|
var result = this.calcDiscount({
|
|
164
164
|
discountList: mergedDiscountList,
|
|
165
165
|
productList: _toConsumableArray(productList),
|
|
@@ -105,10 +105,7 @@ var RulesModule = class extends import_BaseModule.BaseModule {
|
|
|
105
105
|
const filteredOldDiscountList = oldDiscountList.filter(
|
|
106
106
|
(discount) => !discount.isEditMode && (discount.tag !== "good_pass" || discount.isScan)
|
|
107
107
|
);
|
|
108
|
-
const mergedDiscountList = (0, import_utils.uniqueById)(
|
|
109
|
-
(0, import_utils.uniqueById)([...filteredOldDiscountList, ...newDiscountList]),
|
|
110
|
-
"product_id"
|
|
111
|
-
);
|
|
108
|
+
const mergedDiscountList = (0, import_utils.uniqueById)([...filteredOldDiscountList, ...newDiscountList]);
|
|
112
109
|
const result = this.calcDiscount(
|
|
113
110
|
{
|
|
114
111
|
discountList: mergedDiscountList,
|