feat(payments): Add variable pricing with deposit collection
Services can now have variable pricing where: - Final price is determined after service completion - A deposit (fixed amount or percentage) is collected at booking - Customer's saved payment method is charged for remaining balance Changes: - Add variable_pricing, deposit_amount, deposit_percent fields to Service model - Add service FK and final_price fields to Event model - Add AWAITING_PAYMENT status to Event - Add SetFinalPriceView endpoint to charge customer's saved card - Add EventPricingInfoView endpoint for pricing details - Update Services page with variable pricing toggle and deposit config - Show "From $X" and deposit info in customer preview 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -209,6 +209,12 @@ export interface Service {
|
||||
photos?: string[];
|
||||
created_at?: string; // Used for quota overage calculation (oldest archived first)
|
||||
is_archived_by_quota?: boolean; // True if archived due to quota overage
|
||||
// Variable pricing fields
|
||||
variable_pricing?: boolean; // If true, final price is determined after service completion
|
||||
deposit_amount?: number | null; // Fixed deposit amount
|
||||
deposit_percent?: number | null; // Deposit as percentage (0-100)
|
||||
requires_saved_payment_method?: boolean; // If true, customer must have saved card
|
||||
deposit_display?: string | null; // Human-readable deposit description
|
||||
}
|
||||
|
||||
export interface Metric {
|
||||
|
||||
Reference in New Issue
Block a user