File tree Expand file tree Collapse file tree 1 file changed +6
-8
lines changed Expand file tree Collapse file tree 1 file changed +6
-8
lines changed Original file line number Diff line number Diff line change @@ -129,7 +129,6 @@ import { handleTree } from '@/utils/tree'
129
129
import * as MenuApi from ' @/api/system/menu'
130
130
import MenuForm from ' ./MenuForm.vue'
131
131
import { CACHE_KEY , useCache } from ' @/hooks/web/useCache'
132
-
133
132
const { wsCache } = useCache ()
134
133
const { t } = useI18n () // 国际化
135
134
const message = useMessage () // 消息弹窗
@@ -180,19 +179,18 @@ const toggleExpandAll = () => {
180
179
refreshTable .value = true
181
180
})
182
181
}
182
+
183
183
/** 刷新菜单缓存按钮操作 */
184
- const refreshMenu = () => {
185
- ElMessageBox .confirm (' 即将更新缓存刷新浏览器!' , ' 刷新菜单缓存' , {
186
- confirmButtonText: t (' common.ok' ),
187
- cancelButtonText: t (' common.cancel' ),
188
- type: ' warning'
189
- }).then (() => {
184
+ const refreshMenu = async () => {
185
+ try {
186
+ await message .confirm (' 即将更新缓存刷新浏览器!' , ' 刷新菜单缓存' )
190
187
// 清空,从而触发刷新
191
188
wsCache .delete (CACHE_KEY .ROLE_ROUTERS )
192
189
// 刷新浏览器
193
190
location .reload ()
194
- })
191
+ } catch {}
195
192
}
193
+
196
194
/** 删除按钮操作 */
197
195
const handleDelete = async (id : number ) => {
198
196
try {
You can’t perform that action at this time.
0 commit comments