From a623cd24ff3c77c3dbd6c09f9a44ba9f7e5fc81f Mon Sep 17 00:00:00 2001 From: Alexander Ebert Date: Wed, 1 Mar 2017 13:10:51 +0100 Subject: [PATCH] Add cache invalidatin parameter and disabled timeout Closes #2189 Closes #2181 --- com.woltlab.wcf/templates/headIncludeJavaScript.tpl | 1 + wcfsetup/install/files/acp/templates/header.tpl | 1 + wcfsetup/install/files/js/require.config.js | 5 ++++- 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/com.woltlab.wcf/templates/headIncludeJavaScript.tpl b/com.woltlab.wcf/templates/headIncludeJavaScript.tpl index 7dfb376b97..587e2850ba 100644 --- a/com.woltlab.wcf/templates/headIncludeJavaScript.tpl +++ b/com.woltlab.wcf/templates/headIncludeJavaScript.tpl @@ -10,6 +10,7 @@ var LANGUAGE_ID = {@$__wcf->getLanguage()->languageID}; var LANGUAGE_USE_INFORMAL_VARIANT = {if LANGUAGE_USE_INFORMAL_VARIANT}true{else}false{/if}; var TIME_NOW = {@TIME_NOW}; + var LAST_UPDATE_TIME = {@LAST_UPDATE_TIME}; var URL_LEGACY_MODE = false; diff --git a/wcfsetup/install/files/acp/templates/header.tpl b/wcfsetup/install/files/acp/templates/header.tpl index f2c00c3688..cbfc84f6f6 100644 --- a/wcfsetup/install/files/acp/templates/header.tpl +++ b/wcfsetup/install/files/acp/templates/header.tpl @@ -23,6 +23,7 @@ var LANGUAGE_ID = {@$__wcf->getLanguage()->languageID}; var LANGUAGE_USE_INFORMAL_VARIANT = {if LANGUAGE_USE_INFORMAL_VARIANT}true{else}false{/if}; var TIME_NOW = {@TIME_NOW}; + var LAST_UPDATE_TIME = {@LAST_UPDATE_TIME}; var URL_LEGACY_MODE = false; diff --git a/wcfsetup/install/files/js/require.config.js b/wcfsetup/install/files/js/require.config.js index a313b04f39..d8f3a3eebf 100644 --- a/wcfsetup/install/files/js/require.config.js +++ b/wcfsetup/install/files/js/require.config.js @@ -1,3 +1,4 @@ +//noinspection JSUnresolvedVariable requirejs.config({ paths: { enquire: '3rdParty/enquire', @@ -42,7 +43,9 @@ requirejs.config({ 'Upload': 'WoltLabSuite/Core/Upload', 'User': 'WoltLabSuite/Core/User' } - } + }, + urlArgs: 't=' + window.LAST_UPDATE_TIME, + waitSeconds: 0 }); /* Define jQuery shim. We cannot use the shim object in the configuration above, -- 2.20.1