From c4877dd027c53be5d625ca9d1791d40d8493acf7 Mon Sep 17 00:00:00 2001 From: difemaro Date: Wed, 30 Oct 2024 17:19:34 -0500 Subject: [PATCH] Update AutoRefreshDialog.js --- .../Samples/AutoRefresh_seconds/AutoRefreshDialog.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Extensiones/Samples/AutoRefresh_seconds/AutoRefreshDialog.js b/Extensiones/Samples/AutoRefresh_seconds/AutoRefreshDialog.js index f18c330..9de1681 100644 --- a/Extensiones/Samples/AutoRefresh_seconds/AutoRefreshDialog.js +++ b/Extensiones/Samples/AutoRefresh_seconds/AutoRefreshDialog.js @@ -43,8 +43,13 @@ let dashboard = tableau.extensions.dashboardContent.dashboard; let visibleDatasources = []; + let settings = tableau.extensions.settings.getAll(); + $('#interval').val(settings.intervalkey); + + // Load saved selected data sources selectedDatasources = parseSettingsForActiveDataSources(); + // Loop through datasources in this sheet and create a checkbox UI // element for each one. The existing settings are used to // determine whether a datasource is checked by default or not. @@ -122,7 +127,7 @@ tableau.extensions.settings.set(datasourcesSettingsKey, JSON.stringify(selectedDatasources)); tableau.extensions.settings.set(intervalkey, $('#interval').val()); tableau.extensions.settings.saveAsync().then((newSavedSettings) => { - tableau.extensions.ui.closeDialog($('#interval').val()); + tableau.extensions.ui.closeDialog($('#interval').val()); }); } })();