@aptos-scp/scp-component-store-selling-features-domain-model 2.29.0 → 2.29.2
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.
|
@@ -716,6 +716,9 @@ function getOriginalTenderRefundableAmount(originalTender, refundDue, originalTr
|
|
|
716
716
|
return undefined;
|
|
717
717
|
}
|
|
718
718
|
let refundableAmount = new scp_component_business_core_1.Money(0, refundDue.currency);
|
|
719
|
+
const doesNotHaveTransactionTotals = _.isUndefined(withTransactionTotal) &&
|
|
720
|
+
_.isUndefined(withoutTransactionTotal) &&
|
|
721
|
+
_.isUndefined(withOfflineTransactionTotal);
|
|
719
722
|
if (!originalTender.showReference && !_.isUndefined(withTransactionTotal)) {
|
|
720
723
|
refundableAmount = refundableAmount.plus(withTransactionTotal);
|
|
721
724
|
}
|
|
@@ -752,6 +755,9 @@ function getOriginalTenderRefundableAmount(originalTender, refundDue, originalTr
|
|
|
752
755
|
refundableAmount = getLowestRefundDue(refundableAmount.plus(currentTranRefundableAmount), undefined, refundDue);
|
|
753
756
|
}
|
|
754
757
|
});
|
|
758
|
+
refundableAmount = doesNotHaveTransactionTotals
|
|
759
|
+
? adjustAmount(refundableAmount, originalTender.adjustmentAmount)
|
|
760
|
+
: refundableAmount;
|
|
755
761
|
refundableAmount = getLowestRefundDue(refundableAmount, undefined, refundDue);
|
|
756
762
|
return originalTender.isMappedTender
|
|
757
763
|
? refundableAmount
|
|
@@ -40,7 +40,7 @@ class OrderTotalsAccumulator {
|
|
|
40
40
|
* @returns OrderTotals
|
|
41
41
|
*/
|
|
42
42
|
getOrderTotals() {
|
|
43
|
-
const orderTotals = new OrderTotals_1.OrderTotals(this.orderGrandTotal, this.orderTax, this.orderTotalIncludingTax, this.orderTotalExcludingTax, this.orderTotalSavings, this.
|
|
43
|
+
const orderTotals = new OrderTotals_1.OrderTotals(this.orderGrandTotal, this.orderTax, this.orderTotalIncludingTax, this.orderTotalExcludingTax, this.orderTotalSavings, this.orderGrandTotal, this.orderTaxExemptAmount, this.orderItemsQuantity, this.orderNonTaxableFees, this.orderTaxableFeesExcludingTax, this.orderFeesTax);
|
|
44
44
|
return orderTotals;
|
|
45
45
|
}
|
|
46
46
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aptos-scp/scp-component-store-selling-features-domain-model",
|
|
3
|
-
"version": "2.29.
|
|
3
|
+
"version": "2.29.2",
|
|
4
4
|
"description": "This component library provides the common components to handle the coordination of processing the business events from the UI.",
|
|
5
5
|
"private": false,
|
|
6
6
|
"license": "SEE LICENSE IN LICENSE.md",
|