默认首页使用keep-alive缓存

pull/95/MERGE
RuoYi 3 years ago
parent 0e7c45173c
commit 98c538c9e3

@ -66,8 +66,8 @@ export const constantRoutes = [
{ {
path: 'index', path: 'index',
component: (resolve) => require(['@/views/index'], resolve), component: (resolve) => require(['@/views/index'], resolve),
name: '首页', name: 'Index',
meta: { title: '首页', icon: 'dashboard', noCache: true, affix: true } meta: { title: '首页', icon: 'dashboard', affix: true }
} }
] ]
}, },

@ -51,7 +51,7 @@ service.interceptors.response.use(res => {
location.href = '/index'; location.href = '/index';
}) })
}).catch(() => {}); }).catch(() => {});
return Promise.reject() return Promise.reject('令牌验证失败')
} else if (code === 500) { } else if (code === 500) {
Message({ Message({
message: msg, message: msg,

@ -556,7 +556,7 @@
<script> <script>
export default { export default {
name: "index", name: "Index",
data() { data() {
return { return {
// //

Loading…
Cancel
Save