Price Type
Pricing Types
Pricing type determines how the quantity of add-ons is handled during booking.
| Pricing Type | Quantity Behavior | User Can Edit Quantity? |
|---|---|---|
| Per Person | Quantity must match the number of people in the booking | ❌ No (Auto-calculated) |
| Per Item | Quantity can be managed manually by the user | ✅ Yes |
Total Price = Selling Price × Quantity of Package
Add-On Limits
Limits determine how many add-ons can be booked under different conditions.
| Limit Type | Applies To |
|---|---|
| Per Day | Total add-ons sold in one day |
| Per PAX | Maximum add-ons each person (PAX) can buy |
| Per Booking | Maximum total add-ons per single booking |
Validation Rules
| Rule | Validation Condition | Allowed? |
|---|---|---|
| Per Person + Per PAX | People Count × 1 ≤ Per PAX Limit | ✅ Yes |
| Per Person + Per Booking | People Count ≤ Per Booking Limit | ✅ Yes |
| Per Item + Per PAX | (Add-On Quantity ÷ People Count) ≤ Per PAX Limit | ✅ Yes |
| Per Item + Per Booking | Add-On Quantity ≤ Per Booking Limit | ✅ Yes |
| Per Item + Per Day | Total add-ons booked today ≤ Per Day Limit | ✅ Yes |
| Negative or Zero Values | Quantity < 1 | ❌ No |
Test Cases
| Scenario | Input | Calculation | Expected Output |
|---|---|---|---|
| "Per Person" with Per Day limit | Booking People = 3Per Day Limit = 10 | 3 ≤ 10 | ✅ Allowed |
| "Per Person" exceeds Per Day limit | Booking People = 12Per Day Limit = 10 | 12 > 10 | ❌ Not Allowed |
| "Per Person" with Per PAX limit | Booking People = 3Per Pax Limit = 2 | 3 × 1 ≤ 2 | ✅ Allowed |
| "Per Person" with Per Booking limit | Booking People = 5Per Booking Limit = 4 | 5 > 4 | ❌ Not Allowed |
| "Per Item" with Per Day limit | Booking People = 3Add-On Quantity = 7Per Day Limit = 10 | 7 ≤ 10 | ✅ Allowed |
| "Per Item" exceeds Per Day limit | Booking People = 2Add-On Quantity = 12Per Day Limit = 10 | 12 > 10 | ❌ Not Allowed |
| "Per Item" with Per PAX limit | Booking People = 3Add-On Quantity = 6Per Pax Limit = 2 | 6 ÷ 3 = 22 = 2 | ✅ Allowed |
| "Per Item" exceeds Per PAX limit | Booking People = 3Add-On Quantity = 7Per Pax Limit = 2 | 7 ÷ 3 = 2.332.33 > 2 | ❌ Not Allowed |
| "Per Item" with Per Booking limit | Booking People = 4Add-On Quantity = 5Per Booking Limit = 5 | 5 ≤ 5 | ✅ Allowed |
| "Per Item" exceeds Per Booking limit | Booking People = 4Add-On Quantity = 6Per Booking Limit = 5 | 6 > 5 | ❌ Not Allowed |
Error Handling
Same as Private (https://app.clickup.com/9003122396/docs/8ca1fpw-11562/8ca1fpw-46036)