mirror of
https://github.com/DRYTRIX/TimeTracker.git
synced 2026-05-19 12:50:11 -05:00
a50a4ebf2e
- CHANGELOG: document offline queue replay, inventory scopes, client portal reports (date range + CSV), Jira webhook verification; activity feed date validation, PEPPOL exception handling, settings redirect, doc sync - CLIENT_FEATURES_IMPLEMENTATION_STATUS: report date range and CSV export marked as implemented - INCOMPLETE_IMPLEMENTATIONS_ANALYSIS: add Verified 2026-03-16 for webhooks, issues permissions, search API, offline queue, error handling - Add CODEBASE_AUDIT.md with gap analysis and fixed/remaining items
3.3 KiB
3.3 KiB
Client Features Implementation Status
Date: 2026-03-16
Status: Client portal upgrade complete — dashboard customization, reports, activity feed, real-time updates implemented
✅ Completed
1. Time Entry Approval UI
- ✅ Routes in
client_portal.py - ✅ Navigation link with badge
- ✅ Dashboard widget for pending approvals
- ✅ Templates:
approvals.html,approval_detail.html
2. Quote Approval Workflow
- ✅ Accept/Reject routes
- ✅ Quote detail template with action buttons and rejection modal
3. Invoice Payment Links
- ✅ Payment route, invoice detail "Pay Invoice" button, payment status indicators
4. Dashboard enhancements
- ✅ Pending approvals widget, quick actions, statistics cards
5. Client dashboard widget customization (new)
- ✅ Model
ClientPortalDashboardPreferenceand migration140_add_client_portal_dashboard_preferences - ✅ GET/POST
/client-portal/dashboard/preferencesfor widget layout - ✅ Default layout: stats, pending_actions, projects, invoices, time_entries
- ✅ "Customize dashboard" UI (modal with checkboxes, save)
- ✅ Preferences keyed by client_id and optional user_id (portal user)
6. Client-specific reports (first version)
- ✅
ClientReportService.build_report_data()(inclient_report_service.py) - ✅ Reports route uses portal data only; includes project progress, invoice/payment summary, task/status summary, time by date (last 30 days), recent entries
- ✅ Template sections and empty states
7. Project activity feed
- ✅
ClientActivityFeedService.get_client_activity_feed()— unified feed from Activity (project, time_entry for client projects) and Comment (non-internal only) - ✅ Route and template use feed items; correct attributes (action, description, project_name, etc.)
8. Real-time updates (Flask-SocketIO)
- ✅ Client room:
client_portal_{client_id}; join/leave handlers inapi.py - ✅ Auth: only session with
client_portal_idor_user_id(portal user) can join - ✅ Emit
client_notificationwhen a ClientNotification is created - ✅ Emit
client_approval_updatewhen approval is requested or approved/rejected - ✅ Client portal base template: SocketIO script, join on connect, toasts on events
- ✅ Fallback: portal works without WebSocket; counts refresh on next load
Tests added
- Dashboard preferences: GET default, POST then GET persistence, reject invalid widget_ids, require auth
- Reports visibility: report data only for authenticated client; other client’s projects not in page
- Activity feed: require auth, returns feed items; service returns only client’s project activities
- SocketIO:
_get_client_id_from_sessionfor client_portal_id and _user_id; create_notification emits to correct room (mocked)
Optional / future (Phase 2)
- Per-contact preferences (when contact-based login exists)
- Report date range and CSV export: implemented (query param
?days=1–365,?format=csv). PDF export and saved report params remain future. - Activity: log quote/invoice events; optional
visible_to_clienton Activity - Real-time activity feed live updates
- New widget types (e.g. documents, deadlines); admin-defined default layouts
Last Updated: 2026-03-16
Progress: Client portal upgrade complete for dashboard customization, reports, activity feed, and real-time updates.