tripstorekrabi-shared 1.13.34 → 1.13.35

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.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/price.js +8 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tripstorekrabi-shared",
3
- "version": "1.13.34",
3
+ "version": "1.13.35",
4
4
  "description": "Shared library for Trip Store Krabi",
5
5
  "author": "Stefan Sommer <tonprince@gmail.com>",
6
6
  "repository": {
package/price.js CHANGED
@@ -20,6 +20,14 @@ export const EXTRA_PAYMENT_CATEGORIES = [STARTING_POINT_EXTRA_PAYMENT,
20
20
  ADD_ON_EXTRA_PAYMENT,
21
21
  OTHER_EXTRA_PAYMENT];
22
22
 
23
+ export function calculateProductPartnerNetPrice(booking, pricing) {
24
+ return calculateProductPrice(booking, pricing, { paymentMode: PARTNER_PAYMENT_MODE });
25
+ }
26
+
27
+ export function calculateProductOperatorPrice(booking, pricing) {
28
+ return calculateProductPrice(booking, pricing, { paymentMode: OPERATOR_PAYMENT_MODE });
29
+ }
30
+
23
31
  export function calculateProductPrice(booking, pricing, options = { paymentMode: SELLING_PAYMENT_MODE }) {
24
32
  function calculateRetailPrice(commissionRate, price) {
25
33
  return Math.floor(