Building an aggregates-only Resource
I'm building an admin dashboard that will display several aggregate data points sourced from different database tables. These data points should be available from a single AshGraphql query. How would you do this?
I created a resource called
Here is an example of the kind of data I want to expose:
- Member counts
- Signup counts
- Event counts
- Attendee counts
I created a resource called
Dashboard. My first approach was to create a calculation to calculate a data point. That wasn't going anywhere, so I defined an primary read action that loaded the data point from inside the prepare block. That's where I'm at so far. The problem is that calling read() on the API returns nil.Here is an example of the kind of data I want to expose:
- Member counts
- Signup counts
- Event counts
- Attendee counts
