feat: subscription tiers, period filter, dashboards, docs

- Add subscription tiers (Basic/Pro/Business) with listing limits and dynamic commission
- Add daily/monthly period filter on rentals page
- Add landlord dashboard with earnings chart, stat cards, property performance
- Add landlord subscription management page
- Add tenant dashboard with upcoming stays
- Add business model documentation

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
delta-lynx-89e8
2026-02-22 16:19:33 -08:00
parent 68beca8f30
commit dcd2dcb841
24 changed files with 1352 additions and 167 deletions

View File

@@ -0,0 +1,64 @@
# Commission Structure
## Overview
The platform charges two types of commissions: marketplace commissions on product sales and rental commissions on property bookings.
## Marketplace Commission
- **Rate:** 5% of sale price (fixed, configured in PlatformConfig)
- **Payer:** Seller
- **Deduction:** Automatically deducted from seller payout
- **Formula:**
```
Commission = Sale Price × 0.05
Seller Payout = Sale Price - Commission
```
**Example:** Product sold for $100
- Commission: $100 × 5% = $5.00
- Seller receives: $95.00
## Rental Commission
- **Rate:** Variable, 5-10% based on landlord's subscription tier
- **Payer:** Landlord
- **Deduction:** Automatically deducted from landlord payout on booking completion
| Tier | Commission Rate | Effective Savings vs BASIC |
|------|----------------|--------------------------|
| BASIC | 10% | - |
| PRO | 7% | 30% less commission |
| BUSINESS | 5% | 50% less commission |
### Formula
```
Commission Amount = Booking Subtotal × (Tier Commission Rate / 100)
Landlord Payout = Booking Subtotal - Commission Amount
Total Charged to Tenant = Booking Subtotal + Deposit
```
### Calculation Flow
1. Tenant creates booking request
2. System looks up landlord's subscription tier
3. Commission rate is determined from TIER_CONFIG
4. Commission is calculated on subtotal (price × periods)
5. On completion, payout is created: gross - commission = net
### Example: $1,000 Monthly Booking
| Component | BASIC (10%) | PRO (7%) | BUSINESS (5%) |
|-----------|-------------|----------|---------------|
| Subtotal | $1,000 | $1,000 | $1,000 |
| Commission | $100 | $70 | $50 |
| Landlord Payout | $900 | $930 | $950 |
| Platform Revenue | $100 | $70 | $50 |
## Deposit Handling
- Deposits are separate from commission calculations
- Deposits are fully returned on cancellation (regardless of refund policy)
- Deposits are not subject to commission