simonw / django-sql-dashboard

Django app for building dashboards using raw SQL queries
https://django-sql-dashboard.datasette.io/
Apache License 2.0
437 stars 37 forks source link

Greater ability to customise widgets #141

Open drkane opened 3 years ago

drkane commented 3 years ago

At the moment custom widgets are selected by changing column names in the query result, but there's no way to customise the widget itself. Some of the things I've found myself wanting to do include (these are for chart widgets but apply to others too):

There's obviously a trade-off here between simplicity of the current process vs greater customisability. There are probably some workarounds that could work - eg I could have the query return a json column called "settings" and incorporate that into the widget. The alternative would presumably be adding extra fields to the DashboardQuery model - probably title, description, settings (as a JSON field) that were passed to the widget template. But that would need to then have a workflow associated with them for editing.