softseti-sale-calculator-library 3.7.2 → 3.7.3
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/package.json +1 -1
- package/src/SaleCalculator.js +1 -1
package/package.json
CHANGED
package/src/SaleCalculator.js
CHANGED
|
@@ -568,7 +568,7 @@ function calculatePaymentDetails(payment, sale) {
|
|
|
568
568
|
original_amount, // Applied amount in payment's original currency
|
|
569
569
|
original_gived_amount: payment.original_gived_amount, // Original given amount unchanged
|
|
570
570
|
exchange_rate,
|
|
571
|
-
change_amount:
|
|
571
|
+
change_amount: roundCurrency(0, gived_amount - amount) // Change in sale currency
|
|
572
572
|
};
|
|
573
573
|
}
|
|
574
574
|
|