## Features ### Admin Schedule Page (`packages/app/src/pages/admin/schedule.vue`) - Interactive date-based slot editor for managing daily schedules - Real-time slot editing: start/end times, capacity adjustments - Slot deletion with conflict warnings when bookings exist - Add new slots with modal dialog - Live booking status display (booked count, people names) - Publish/Save changes with sync feedback - Revert unsaved changes with confirmation - Skeleton loading states and empty state handling - Responsive design with optimized mobile UX ### Backend Enhancements - **New DTO** (`PublishDaySlotsDto`): Structured slot publishing with validation - Date string validation - Slot array with existing slot IDs for updates - Time and capacity validation per slot - **Schedule Preview API** (`getSchedulePreview`): - Check for existing published slots - Fallback to active WeekTemplates for unpublished dates - Unified response format with isPublished flag - **Publish Slots API** (`publishDaySlots`): - Atomic transaction for consistency - Update existing slots with new times/capacity - Create new slots from template data - Delete unpublished slots or set to CLOSED if bookings exist - Prevent capacity reduction below existing bookings - Returns all published slots for feedback ### State Management - Enhanced admin store with schedule state - Support for pending/unsaved slot changes - Optimistic UI updates with server sync ### Documentation - Comprehensive scheduling system architecture docs - Quick reference for admin workflows - Flow diagrams and state transitions - Implementation guide for future maintenance ## Breaking Changes None ## Testing Recommendations - Create slots for future dates via schedule editor - Verify booking prevention for locked/full slots - Test capacity adjustments with existing bookings - Confirm template-based schedule generation - Verify transaction rollback on publish failures Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
128 lines
2.8 KiB
JSON
128 lines
2.8 KiB
JSON
{
|
|
"pages": [
|
|
{
|
|
"path": "pages/home/index",
|
|
"style": {
|
|
"navigationBarTitleText": "首页",
|
|
"navigationStyle": "custom"
|
|
}
|
|
},
|
|
{
|
|
"path": "pages/booking/index",
|
|
"style": {
|
|
"navigationBarTitleText": "预约课程"
|
|
}
|
|
},
|
|
{
|
|
"path": "pages/profile/index",
|
|
"style": {
|
|
"navigationBarTitleText": "我的"
|
|
}
|
|
},
|
|
{
|
|
"path": "pages/card/detail",
|
|
"style": {
|
|
"navigationBarTitleText": "购买会员卡"
|
|
}
|
|
},
|
|
{
|
|
"path": "pages/profile/membership",
|
|
"style": {
|
|
"navigationBarTitleText": "我的会员卡"
|
|
}
|
|
},
|
|
{
|
|
"path": "pages/profile/bookings",
|
|
"style": {
|
|
"navigationBarTitleText": "我的预约"
|
|
}
|
|
},
|
|
{
|
|
"path": "pages/profile/info",
|
|
"style": {
|
|
"navigationBarTitleText": "个人信息"
|
|
}
|
|
},
|
|
{
|
|
"path": "pages/admin/index",
|
|
"style": {
|
|
"navigationBarTitleText": "管理中心"
|
|
}
|
|
},
|
|
{
|
|
"path": "pages/admin/schedule",
|
|
"style": {
|
|
"navigationBarTitleText": "排课管理"
|
|
}
|
|
},
|
|
{
|
|
"path": "pages/admin/week-template",
|
|
"style": {
|
|
"navigationBarTitleText": "排课模板"
|
|
}
|
|
},
|
|
{
|
|
"path": "pages/admin/slot-adjust",
|
|
"style": {
|
|
"navigationBarTitleText": "时段调整"
|
|
}
|
|
},
|
|
{
|
|
"path": "pages/admin/members",
|
|
"style": {
|
|
"navigationBarTitleText": "会员管理"
|
|
}
|
|
},
|
|
{
|
|
"path": "pages/admin/orders",
|
|
"style": {
|
|
"navigationBarTitleText": "订单管理"
|
|
}
|
|
},
|
|
{
|
|
"path": "pages/admin/card-types",
|
|
"style": {
|
|
"navigationBarTitleText": "卡种管理"
|
|
}
|
|
},
|
|
{
|
|
"path": "pages/admin/studio",
|
|
"style": {
|
|
"navigationBarTitleText": "工作室设置"
|
|
}
|
|
}
|
|
],
|
|
"globalStyle": {
|
|
"navigationBarTextStyle": "black",
|
|
"navigationBarTitleText": "普拉提约课",
|
|
"navigationBarBackgroundColor": "#ffffff",
|
|
"backgroundColor": "#f5f5f5"
|
|
},
|
|
"tabBar": {
|
|
"color": "#999999",
|
|
"selectedColor": "#1a1a2e",
|
|
"backgroundColor": "#ffffff",
|
|
"borderStyle": "black",
|
|
"list": [
|
|
{
|
|
"pagePath": "pages/home/index",
|
|
"text": "场馆首页",
|
|
"iconPath": "static/tab/home.png",
|
|
"selectedIconPath": "static/tab/home-active.png"
|
|
},
|
|
{
|
|
"pagePath": "pages/booking/index",
|
|
"text": "课程预约",
|
|
"iconPath": "static/tab/booking.png",
|
|
"selectedIconPath": "static/tab/booking-active.png"
|
|
},
|
|
{
|
|
"pagePath": "pages/profile/index",
|
|
"text": "个人中心",
|
|
"iconPath": "static/tab/profile.png",
|
|
"selectedIconPath": "static/tab/profile-active.png"
|
|
}
|
|
]
|
|
}
|
|
}
|