feat: complete UI/UX overhaul - dashboard unification, calendar UX, mobile optimization
- Dashboard redesign as command center with filters, quick actions, inline approve/reject - Reusable components: BookingRow, BookingFilters, ActionMenu, BookingPreviewModal, BookingEditModal - Calendar: drag & drop reschedule, eventClick preview modal, grid/list toggle - Mobile: segmented control bookings/calendar toggle, compact pills, responsive layout - Collapsible filters with active count badge - Smart menu positioning with Teleport - Calendar/list bidirectional data sync - Navigation: unified History page, removed AdminPending - Google Calendar OAuth integration - Dark mode contrast improvements, breadcrumb navigation - useLocalStorage composable for state persistence Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -12,6 +12,7 @@ import type {
|
||||
Booking,
|
||||
BookingCreate,
|
||||
BookingUpdate,
|
||||
BookingAdminCreate,
|
||||
BookingTemplate,
|
||||
BookingTemplateCreate,
|
||||
Notification,
|
||||
@@ -202,6 +203,17 @@ export const bookingsApi = {
|
||||
|
||||
// Admin Bookings API
|
||||
export const adminBookingsApi = {
|
||||
getAll: async (params?: {
|
||||
status?: string
|
||||
space_id?: number
|
||||
user_id?: number
|
||||
start?: string
|
||||
limit?: number
|
||||
}): Promise<Booking[]> => {
|
||||
const response = await api.get<Booking[]>('/admin/bookings/all', { params })
|
||||
return response.data
|
||||
},
|
||||
|
||||
getPending: async (filters?: { space_id?: number; user_id?: number }): Promise<Booking[]> => {
|
||||
const response = await api.get<Booking[]>('/admin/bookings/pending', { params: filters })
|
||||
return response.data
|
||||
@@ -228,6 +240,11 @@ export const adminBookingsApi = {
|
||||
): Promise<Booking> => {
|
||||
const response = await api.put<Booking>(`/admin/bookings/${id}/reschedule`, data)
|
||||
return response.data
|
||||
},
|
||||
|
||||
create: async (data: BookingAdminCreate): Promise<Booking> => {
|
||||
const response = await api.post<Booking>('/admin/bookings', data)
|
||||
return response.data
|
||||
}
|
||||
}
|
||||
|
||||
@@ -354,7 +371,14 @@ export const googleCalendarApi = {
|
||||
},
|
||||
|
||||
disconnect: async (): Promise<{ message: string }> => {
|
||||
const response = await api.delete<{ message: string }>('/integrations/google/disconnect')
|
||||
const response = await api.post<{ message: string }>('/integrations/google/disconnect')
|
||||
return response.data
|
||||
},
|
||||
|
||||
sync: async (): Promise<{ synced: number; created: number; updated: number; failed: number; total_bookings: number }> => {
|
||||
const response = await api.post<{ synced: number; created: number; updated: number; failed: number; total_bookings: number }>(
|
||||
'/integrations/google/sync'
|
||||
)
|
||||
return response.data
|
||||
},
|
||||
|
||||
|
||||
Reference in New Issue
Block a user