Any best practices on allowing enabling
# avo-2
a
Any best practices on allowing/enabling user defined dashboards/cards?
l
dashboards and cards both have the
self.visible
block where you have access to the
current_user
variable and you can allow/disallow users to view them
a
that's not really what I'm talking about
I want users to be able to define their own cards and dashboards
so I'd really be storing the contents of the dashboards in a DB vs in the file, I'd imagine. Cards can probably be more templatized so they'd have to 'choose' from components in the card
l
that's not an Avo feature yet
I guess you could hack it and build it
for cards: - create a cards model & resource - probably monkey patch the
items
method on the
BaseDashboard
where you'd add your custom-defined cards for dashbords: - create dashboard model & resource - add those dashboards somehow to
Avo::App.dashboards
so they will be available like the ones defined by the files
you can go pretty wild with the configuration on both of them (atuhorization, options, description, rows, cols, etc)
if you find a place where we can improve the API to accomodate this, please file in a PR. we'd love to help more people to build that kidn of feature
a
ok great, I'll see what I can do
l
cool!
so yeah, this is on the table