Change window.reload to hard reload

This commit is contained in:
Alicia Sykes 2021-06-21 19:22:58 +01:00
parent 5b568ccac0
commit 75fc677ff9
2 changed files with 3 additions and 14 deletions

View File

@ -3,7 +3,7 @@
<TabItem name="Config" class="main-tab"> <TabItem name="Config" class="main-tab">
<div class="main-options-container"> <div class="main-options-container">
<h2>Configuration Options</h2> <h2>Configuration Options</h2>
<a href="/conf.yml" download class="hyperlink-wrapper"> <a class="hyperlink-wrapper" @click="downloadConfigFile('conf.yml', yaml)">
<button class="config-button center"> <button class="config-button center">
<DownloadIcon class="button-icon"/> <DownloadIcon class="button-icon"/>
Download Config Download Config
@ -13,10 +13,6 @@
<EditIcon class="button-icon"/> <EditIcon class="button-icon"/>
Edit Config Edit Config
</button> </button>
<button class="config-button center" @click="goToMetaEdit()">
<MetaDataIcon class="button-icon"/>
Edit Meta Data
</button>
<button class="config-button center" @click="goToCustomCss()"> <button class="config-button center" @click="goToCustomCss()">
<CustomCssIcon class="button-icon"/> <CustomCssIcon class="button-icon"/>
Edit Custom CSS Edit Custom CSS
@ -59,9 +55,6 @@
<TabItem name="Edit Config"> <TabItem name="Edit Config">
<JsonEditor :config="config" /> <JsonEditor :config="config" />
</TabItem> </TabItem>
<TabItem name="Edit Site Meta">
<EditSiteMeta :config="config" />
</TabItem>
<TabItem name="Custom Styles"> <TabItem name="Custom Styles">
<CustomCssEditor :config="config" initialCss="hello" /> <CustomCssEditor :config="config" initialCss="hello" />
</TabItem> </TabItem>
@ -76,7 +69,6 @@ import 'highlight.js/styles/mono-blue.css';
import JsonToYaml from '@/utils/JsonToYaml'; import JsonToYaml from '@/utils/JsonToYaml';
import { localStorageKeys, modalNames } from '@/utils/defaults'; import { localStorageKeys, modalNames } from '@/utils/defaults';
import EditSiteMeta from '@/components/Configuration/EditSiteMeta';
import JsonEditor from '@/components/Configuration/JsonEditor'; import JsonEditor from '@/components/Configuration/JsonEditor';
import CustomCssEditor from '@/components/Configuration/CustomCss'; import CustomCssEditor from '@/components/Configuration/CustomCss';
import RebuildApp from '@/components/Configuration/RebuildApp'; import RebuildApp from '@/components/Configuration/RebuildApp';
@ -84,7 +76,6 @@ import RebuildApp from '@/components/Configuration/RebuildApp';
import DownloadIcon from '@/assets/interface-icons/config-download-file.svg'; import DownloadIcon from '@/assets/interface-icons/config-download-file.svg';
import DeleteIcon from '@/assets/interface-icons/config-delete-local.svg'; import DeleteIcon from '@/assets/interface-icons/config-delete-local.svg';
import EditIcon from '@/assets/interface-icons/config-edit-json.svg'; import EditIcon from '@/assets/interface-icons/config-edit-json.svg';
import MetaDataIcon from '@/assets/interface-icons/config-meta-data.svg';
import CustomCssIcon from '@/assets/interface-icons/config-custom-css.svg'; import CustomCssIcon from '@/assets/interface-icons/config-custom-css.svg';
import CloudIcon from '@/assets/interface-icons/cloud-backup-restore.svg'; import CloudIcon from '@/assets/interface-icons/cloud-backup-restore.svg';
import RebuildIcon from '@/assets/interface-icons/application-rebuild.svg'; import RebuildIcon from '@/assets/interface-icons/application-rebuild.svg';
@ -109,7 +100,6 @@ export default {
}, },
}, },
components: { components: {
EditSiteMeta,
JsonEditor, JsonEditor,
CustomCssEditor, CustomCssEditor,
RebuildApp, RebuildApp,
@ -117,7 +107,6 @@ export default {
DeleteIcon, DeleteIcon,
EditIcon, EditIcon,
CloudIcon, CloudIcon,
MetaDataIcon,
CustomCssIcon, CustomCssIcon,
RebuildIcon, RebuildIcon,
}, },
@ -156,7 +145,7 @@ export default {
localStorage.clear(); localStorage.clear();
this.$toasted.show('Data cleared succesfully'); this.$toasted.show('Data cleared succesfully');
setTimeout(() => { setTimeout(() => {
location.reload(); // eslint-disable-line no-restricted-globals location.reload(true); // eslint-disable-line no-restricted-globals
}, 1900); }, 1900);
} }
}, },

View File

@ -90,7 +90,7 @@ export default {
registerLogout(); registerLogout();
this.$toasted.show('Logged Out'); this.$toasted.show('Logged Out');
setTimeout(() => { setTimeout(() => {
location.reload(); // eslint-disable-line no-restricted-globals location.reload(true); // eslint-disable-line no-restricted-globals
}, 100); }, 100);
}, },
isUserLoggedIn() { isUserLoggedIn() {