From 34fc0a13ad9053cfc065871dfdc596d5bc2bf190 Mon Sep 17 00:00:00 2001 From: Frost-ZX <30585462+Frost-ZX@users.noreply.github.com> Date: Mon, 3 May 2021 00:48:06 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=94=B9=E6=9C=AC=E5=9C=B0=E5=82=A8?= =?UTF-8?q?=E5=AD=98=E9=A1=B9=E5=90=8D=E3=80=81=E6=9B=B4=E6=94=B9=E6=8F=90?= =?UTF-8?q?=E7=A4=BA=E7=BB=84=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/App.vue | 4 ++-- src/views/Settings.vue | 14 +++++++------- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/App.vue b/src/App.vue index 3c23e79..8cd81cb 100644 --- a/src/App.vue +++ b/src/App.vue @@ -112,7 +112,7 @@ export default { clearTimeout(this.debounce.saveConfig); this.debounce.saveConfig = setTimeout(() => { - localStorage.setItem('config', JSON.stringify(obj)); + localStorage.setItem('navConfig', JSON.stringify(obj)); }, 2000); }, deep: true @@ -130,7 +130,7 @@ export default { } }, mounted() { - var configStr = localStorage.getItem('config'); + var configStr = localStorage.getItem('navConfig'); var configObj = {}; if (configStr != null) { diff --git a/src/views/Settings.vue b/src/views/Settings.vue index 33118c1..b5153a7 100644 --- a/src/views/Settings.vue +++ b/src/views/Settings.vue @@ -62,14 +62,14 @@ export default { if (type == 'cache') { localStorage.removeItem('navLinksCache'); } else if (type == 'settings') { - localStorage.removeItem('config'); + localStorage.removeItem('navConfig'); } else { return } - this.$notify({ - type: 'success', - message: '已清除,2s 后自动刷新' + this.$message({ + message: '已清除,2s 后自动刷新', + type: 'success' }); setTimeout(() => { @@ -78,9 +78,9 @@ export default { }).catch(() => { - this.$notify({ - type: 'info', - message: '取消清除' + this.$message({ + message: '取消清除', + type: 'info' }); });