tripstorekrabi-shared 1.13.24 → 1.13.25
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/price.js +4 -1
package/package.json
CHANGED
package/price.js
CHANGED
|
@@ -194,7 +194,10 @@ export function calculateExtraPayments(booking, selling = true, calculationMode
|
|
|
194
194
|
export function getExtraPaymentsPaidWithPartner(booking, product) {
|
|
195
195
|
let startingPoint = findStartingPoint(product, booking.startingPointId);
|
|
196
196
|
let endPoint = findEndPoint(product, booking.endPointId);
|
|
197
|
-
let addOnDefs =
|
|
197
|
+
let addOnDefs = {};
|
|
198
|
+
(product.addOns ?? []).forEach((addOn) => {
|
|
199
|
+
addOnDefs[addOn.id] = addOn;
|
|
200
|
+
});
|
|
198
201
|
let addOns = Object.keys(booking.addOns).filter((id) => addOnDefs[id] != null).map(([id, addOn]) => {
|
|
199
202
|
let addOnDef = addOnDefs[id];
|
|
200
203
|
|