feat: hourly pricing + category base prices in booking modal + availability grid
- Add hourly_price column to rate_overrides, base_price/allow_hourly/hourly_base_price to room_categories (migration 033) - Update categories and rate-overrides backend routes to handle new fields - AvailabilityPage: hourly/nightly mode toggle, period prices auto-applied to grid with 'П' indicator, confirmation dialog when overriding period prices - BookingModal: nightly/hourly toggle at top, pricing hierarchy (override → category base → room rate) - RoomCategoriesPage: base_price/allow_hourly/hourly_base_price fields in category form; inline rooms panel - CalendarPage + BookingCalendar: pass hourlyPriceOverrides and categoryBasePrices down to BookingModal Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -745,6 +745,9 @@ export interface CategoryApi {
|
||||
amenities: string[]
|
||||
photos: string[]
|
||||
sort_order: number
|
||||
base_price: number
|
||||
allow_hourly: boolean
|
||||
hourly_base_price: number
|
||||
created_at: string
|
||||
}
|
||||
|
||||
@@ -755,6 +758,9 @@ export interface CategoryPayload {
|
||||
amenities?: string[]
|
||||
photos?: string[]
|
||||
sort_order?: number
|
||||
base_price?: number
|
||||
allow_hourly?: boolean
|
||||
hourly_base_price?: number
|
||||
}
|
||||
|
||||
export interface TariffApi {
|
||||
@@ -794,6 +800,7 @@ export interface RateOverrideApi {
|
||||
minNights: number
|
||||
channelPrices: Record<string, number>
|
||||
closed: boolean
|
||||
hourlyPrice?: number | null
|
||||
}
|
||||
|
||||
export interface RateOverridePayload {
|
||||
@@ -804,6 +811,7 @@ export interface RateOverridePayload {
|
||||
min_nights?: number
|
||||
channel_prices?: Record<string, number>
|
||||
closed?: boolean
|
||||
hourly_price?: number | null
|
||||
}
|
||||
|
||||
export interface RatePeriodApi {
|
||||
|
||||
Reference in New Issue
Block a user