It's now possible to maintain parameter states between different sessions. Instead of using simple parameters, objects inside the special namespace storage
can be saved and restored.
Dashboards can store values as per the user preferences. Let's suppose you have a dashboard where you want to persist the status next time you get on the dashboard. It's possible to do this with the storage functionality of CDF. Each time that the function dashboard.saveStorage()
is called, CDF will store the content of the dashboard.storage
object. When the dashboard is loaded for that user, the dashboard will have access to the object dashboard.storage
where all the collections (objects and arrays) or functions are defined.
Tip
Don't forget to save the storage:
Storage will only be saved on the server side after running the dashboard.saveStorage()
function; otherwise if you refresh the dashboard before saving it, you will notice that you have lost the last changes before the last save.
You can...