VolkovLabs / business-forms

The Business Forms panel is a conceptually new plugin for Grafana. It is the first plugin that allows inserting and updating application data, as well as modifying configuration directly from your Grafana dashboard.
https://docs.volkovlabs.io
Apache License 2.0
86 stars 10 forks source link

how to save updated element on dashboard even after dashboard load #335

Closed vaniiplon closed 9 months ago

vaniiplon commented 10 months ago

hello Mikhail,

tried with new version released 3.5.0 with dashboard sync option. But still after dashboard reload all dashboard updated elements are going to default values.

Please provide a suggestion for updated element to show on dashboard as it is, so that our customers will have idea of previously set dashboard value. Here, we are not using any database to store the values, so we need an option of saving dashboard

Thanks in advance.

asimonok commented 9 months ago

@vnvasireddy you can use context.panel.onOptionsChange in the Element Value Changed code. Also you need to save dashboard after all initial values are set in the panel.

Screenshot 2024-02-28 at 14 07 02
context.panel.onOptionsChange({
  ...context.panel.options,
  elements: context.panel.elements,
});

Please let us know if there is anything else

vaniiplon commented 7 months ago

Thank you its working