fix: Replace GraphQL with REST API for home page dashboard
GraphQL endpoint was returning 400 errors due to authentication issues with the GqlAuthGuard. Replaced GraphQL query with REST API calls to match the working insights page pattern. Changes: - Removed useQuery(GET_DASHBOARD) GraphQL call - Added REST API calls: childrenApi.getChildren(), trackingApi.getActivities() - Calculate today's summary from activities client-side - Load children and dashboard data separately - Removed all GraphQL debug logging Now home page uses same REST pattern as insights page: 1. Load children via childrenApi 2. Load activities via trackingApi 3. Calculate summary from filtered activities This eliminates the GraphQL 400 errors and makes Today's Summary display correctly with feeding count, sleep duration, diaper count. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user