From 36774c9f41f20e076116e4a0a001c43380f9a8be Mon Sep 17 00:00:00 2001 From: Joseph Nuthalapati Date: Fri, 10 Aug 2018 18:02:06 +0530 Subject: [PATCH] turbolinks: Reload page using JavaScript Using the existing meta tag for refresh as a noscript fallback. Fixes #1350 Signed-off-by: Joseph Nuthalapati Reviewed-by: James Valleroy --- .../diagnostics/templates/diagnostics.html | 13 ++++++++- .../monkeysphere/templates/monkeysphere.html | 12 +++++++- plinth/modules/openvpn/templates/openvpn.html | 11 ++++++- plinth/modules/tor/templates/tor.html | 10 ++++++- .../modules/upgrades/templates/upgrades.html | 10 ++++++- plinth/templates/setup.html | 15 ++++++++-- static/themes/default/js/refresh.js | 29 +++++++++++++++++++ 7 files changed, 92 insertions(+), 8 deletions(-) create mode 100644 static/themes/default/js/refresh.js diff --git a/plinth/modules/diagnostics/templates/diagnostics.html b/plinth/modules/diagnostics/templates/diagnostics.html index 08d0fcd77..797d1356f 100644 --- a/plinth/modules/diagnostics/templates/diagnostics.html +++ b/plinth/modules/diagnostics/templates/diagnostics.html @@ -19,11 +19,14 @@ {% endcomment %} {% load i18n %} +{% load static %} {% block page_head %} {% if is_running %} - + {% endif %} {% endblock %} @@ -73,3 +76,11 @@ {% endif %} {% endblock %} + + +{% block page_js %} + {% if is_running %} + + {% endif %} +{% endblock %} + diff --git a/plinth/modules/monkeysphere/templates/monkeysphere.html b/plinth/modules/monkeysphere/templates/monkeysphere.html index ebac142df..b230d53e8 100644 --- a/plinth/modules/monkeysphere/templates/monkeysphere.html +++ b/plinth/modules/monkeysphere/templates/monkeysphere.html @@ -20,11 +20,14 @@ {% load bootstrap %} {% load i18n %} +{% load static %} {% block page_head %} {% if running %} - + {% endif %}