-
- Downloads
Multi Series Dashcards Render with Filters Applied To All Series (#43428)
* Multi Series Dashcards Render with Filters Applied To All Series Fixes: #39083 Multi-series dashcards now properly render when a subscription is set up with filters that impact the values of each card in the multi-series card. * Small refactor for executing dashcards in a pulse context. - move execute-dashboard-subscription to pulse.util - this fn now will also execute all card series cards and put those results into a list on the key :series-results in the dashcard which is then used in the render multimethod to send the correct data to the javascript context A small todo was taken care of as well, we can now use :dashboard-subscription in the :context key * Fix up render fn The shape of hte data going into the javascript was a bit unclear before. This keeps things a little more understandable. Next step is probably to create some Malli schemas inside the js_svg namespace to document and enforce the needed data shapes * pull :data up a level from :result in the series cards * Update src/metabase/pulse/render/body.clj Co-authored-by:Ngoc Khuat <qn.khuat@gmail.com> * Remove unneeded let * set/rename-keys won't work here because we raise the :data key I've realised a suggested change to just use set/rename-keys won't do what we need. We need instead to raise :data from within the result key up to the same level (and dissoc result). I've renamed the helper function to make its purpose a bit clearer --------- Co-authored-by:
Ngoc Khuat <qn.khuat@gmail.com>
Showing
- src/metabase/lib/schema/info.cljc 1 addition, 0 deletionssrc/metabase/lib/schema/info.cljc
- src/metabase/pulse.clj 2 additions, 43 deletionssrc/metabase/pulse.clj
- src/metabase/pulse/render/body.clj 18 additions, 21 deletionssrc/metabase/pulse/render/body.clj
- src/metabase/pulse/util.clj 46 additions, 20 deletionssrc/metabase/pulse/util.clj
- test/metabase/pulse/render/body_test.clj 70 additions, 13 deletionstest/metabase/pulse/render/body_test.clj
- test/metabase/pulse/render/test_util.clj 17 additions, 18 deletionstest/metabase/pulse/render/test_util.clj
Loading
Please register or sign in to comment