F
Filament9mo ago
pelmer

Can you use StatsOverviewWidget in infolist?

Can you use StatsOverviewWidget in infolist? I managed to render it on my infolist, but how do I get the current model/record to pull out the stats for that model? Is there a way to display a bar chart with the StatsOverviewWidget?
Solution:
Fair enough, but a ViewRecord is still a page which has widgets and also infolists. They aren’t necessarily mutually exclusive but the page is the livewire component which maintains the record. So both the widget and infolist have access to the same record.
Jump to solution
8 Replies
awcodes
awcodes9mo ago
What? Widgets and info lists are 2 separate things. Why would you have a widget inside an info list.
pelmer
pelmerOP9mo ago
I want some stats for the user. LTV, Booking count etc.
pelmer
pelmerOP9mo ago
This is how it looks like now, with hard coded stats. I think that makes sense.
No description
Solution
awcodes
awcodes9mo ago
Fair enough, but a ViewRecord is still a page which has widgets and also infolists. They aren’t necessarily mutually exclusive but the page is the livewire component which maintains the record. So both the widget and infolist have access to the same record.
awcodes
awcodes9mo ago
The page is the main livewire component.
pelmer
pelmerOP9mo ago
Ah, yes. Thank you. That helped. I didn't pass in the Infolist object to my infolist 🙂 Is there a way to make it a bar chart?
awcodes
awcodes9mo ago
You have to use a chart widget if you want a bar chart. Stat widgets don’t support charts.
pelmer
pelmerOP9mo ago
Ok, I will do that. Thank you
Want results from more Discord servers?
Add your server