support clearing application code cache
This commit is contained in:
@@ -101,6 +101,8 @@
|
||||
<f7-actions-group v-if="isSupportedFileCache && fileCacheStatistics">
|
||||
<f7-actions-button :class="{ 'disabled': loading || !isSupportedFileCache || !fileCacheStatistics }"
|
||||
@click="clearMapCache">{{ tt('Clear Map Data Cache') }}</f7-actions-button>
|
||||
<f7-actions-button :class="{ 'disabled': loading || !isSupportedFileCache || !fileCacheStatistics }"
|
||||
@click="clearApplicationCodeFileCache">{{ tt('Clear Application Code Cache') }}</f7-actions-button>
|
||||
<f7-actions-button :class="{ 'disabled': loading || !isSupportedFileCache || !fileCacheStatistics }"
|
||||
@click="clearAllFileCache">{{ tt('Clear All File Cache') }}</f7-actions-button>
|
||||
</f7-actions-group>
|
||||
@@ -141,6 +143,7 @@ const {
|
||||
exchangeRatesDataCacheExpiration,
|
||||
loadCacheStatistics,
|
||||
clearMapDataCache,
|
||||
clearApplicationCodeCache,
|
||||
clearAllBrowserCaches,
|
||||
clearExchangeRatesDataCache
|
||||
} = useAppBrowserCacheSettingPageBase();
|
||||
@@ -165,6 +168,14 @@ function clearMapCache(): void {
|
||||
});
|
||||
}
|
||||
|
||||
function clearApplicationCodeFileCache(): void {
|
||||
showConfirm('Are you sure you want to clear application code cache?', () => {
|
||||
clearApplicationCodeCache().then(() => {
|
||||
loadCacheStatistics(true);
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
function clearAllFileCache(): void {
|
||||
showConfirm('Are you sure you want to clear all file cache?', () => {
|
||||
clearAllBrowserCaches().then(() => {
|
||||
|
||||
Reference in New Issue
Block a user