Commit graph

14 commits

Author SHA1 Message Date
John Mizerek
8108924dcd Add chat modal to HUD for responding to chat tasks
- When accepting a chat task, automatically opens chat modal
- Chat modal shows message history and allows sending replies
- Auto-polls for new messages every 2 seconds
- End Chat button to complete the chat task

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-08 15:22:19 -08:00
John Mizerek
641b238de8 Add location and color styling to HUD task detail overlay
- Display ServicePointName in task detail overlay when available
- Style task details text in the bar's category color

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-08 15:11:30 -08:00
John Mizerek
a998ff890a Fix HUD task bar not disappearing after accept/complete
Changed t.ID to t.TaskID in three places - the API returns TaskID
not ID, so filtering and lookups were failing.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-08 14:52:50 -08:00
John Mizerek
3d6856f108 KDS/HUD: Add online/offline connection detection
- Listen to browser online/offline events
- Check navigator.onLine before API calls
- Update status indicator immediately when connection changes
- Auto-refresh when coming back online

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-07 17:22:14 -08:00
John Mizerek
1210249f54 Normalize database column and table names across entire codebase
Update all SQL queries, query result references, and ColdFusion code to match
the renamed database schema. Tables use plural CamelCase, PKs are all `ID`,
column prefixes stripped (e.g. BusinessName→Name, UserFirstName→FirstName).

Key changes:
- Strip table-name prefixes from all column references (Businesses, Users,
  Addresses, Hours, Menus, Categories, Items, Stations, Orders,
  OrderLineItems, Tasks, TaskCategories, TaskRatings, QuickTaskTemplates,
  ScheduledTaskDefinitions, ChatMessages, Beacons, ServicePoints, Employees,
  VisitorTrackings, ApiPerfLogs, tt_States, tt_Days, tt_AddressTypes,
  tt_OrderTypes, tt_TaskTypes)
- Rename PK references from {TableName}ID to ID in all queries
- Rewrite 7 admin beacon files to use ServicePoints.BeaconID instead of
  dropped lt_Beacon_Businesses_ServicePoints link table
- Rewrite beacon assignment files (list, save, delete) for new schema
- Fix FK references incorrectly changed to ID (OrderLineItems.OrderID,
  Categories.MenuID, Tasks.CategoryID, ServicePoints.BeaconID)
- Update Addresses: AddressLat→Latitude, AddressLng→Longitude
- Update Users: UserPassword→Password, UserIsEmailVerified→IsEmailVerified,
  UserIsActive→IsActive, UserBalance→Balance, etc.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-30 15:39:12 -08:00
John Mizerek
8f9da2fbf0 Add Manage Menus toolbar button, photo upload, and various improvements
- Move menu manager button to toolbar next to Save Menu for visibility
- Implement server-side photo upload for menu items
- Strip base64 data URLs from save payload to reduce size
- Add scheduled tasks, quick tasks, ratings, and task categories APIs
- Add vertical support and brand color features

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-28 14:43:41 -08:00
John Mizerek
51e979a679 Remove URL params - use localStorage for auth
- HUD reads businessId from localStorage instead of ?b= param
- Portal opens HUD/quick-tasks without URL params
- Business select auto-proceeds on selection (no button needed)
- Quick tasks reads from payfrit_portal_business localStorage

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-27 21:32:47 -08:00
John Mizerek
f96d8f4fe3 Update HUD default business to 47
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-27 21:27:45 -08:00
John Mizerek
49ef916f34 Remove demo mode from HUD, fix task creation timezone
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-27 21:25:05 -08:00
John Mizerek
d4cc4b4a6c Fix service bell task creation for Android app
- Update create.cfm to handle TaskTypeID for service bell tasks
- Update hud.js to prefer TaskTypeColor/TaskTypeName for task display

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-27 20:52:59 -08:00
John Mizerek
3df846a31b Fix HUD business name - get from listPending API
The previous approach called getBusiness which requires auth.
Now listPending returns BUSINESS_NAME and HUD uses that.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-19 20:33:09 -08:00
John Mizerek
30570c3772 Add business name to HUD header, fix portal HUD link
- HUD now displays "Payfrit Tasks - <BusinessName>" by fetching from getBusiness API
- Fixed portal Task HUD button to link to /hud/index.html instead of /hud/

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-19 20:23:52 -08:00
John Mizerek
8092384702 Add team endpoint and chat features for portal
- Add /api/portal/team.cfm for employee listing
- Add chat endpoints (getMessages, sendMessage, markRead, getActiveChat)
- Add OTP authentication endpoints
- Add address management endpoints (delete, setDefault, states)
- Add task completion and chat task endpoints
- Update Application.cfm allowlist

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-11 17:03:55 -08:00
John Mizerek
0765dc1e27 Add business portal, Stripe Connect, beacon APIs, and task system
Portal:
- New business portal UI (portal/index.html, portal.css, portal.js)
- Dashboard with real-time stats (orders today, revenue, pending, menu items)
- Business info endpoint (api/businesses/get.cfm)
- Portal stats endpoint (api/portal/stats.cfm)
- Menu page links to existing full-featured menu editor

Stripe Connect:
- Onboarding endpoint (api/stripe/onboard.cfm)
- Status check endpoint (api/stripe/status.cfm)
- Payment intent creation (api/stripe/createPaymentIntent.cfm)
- Webhook handler (api/stripe/webhook.cfm)

Beacon APIs:
- List all beacons (api/beacons/list_all.cfm)
- Get business from beacon (api/beacons/getBusinessFromBeacon.cfm)

Task System:
- List pending tasks (api/tasks/listPending.cfm)
- Accept task (api/tasks/accept.cfm)

Other:
- HUD interface for quick order status display
- KDS debug/test pages
- Updated Application.cfm with public endpoint allowlist
- Order status check improvements

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-01 23:38:26 -08:00