This commit is contained in:
xulu
2021-08-22 19:41:25 +08:00
parent 4d8c396790
commit 21e5fc549a
21 changed files with 602 additions and 360 deletions

View File

@@ -31,7 +31,7 @@ router.beforeEach((to, from, next) => {
document.title = `${to.meta.title} | Traditional Medicine Research`;
const role = localStorage.getItem('U_name');
const userrole = localStorage.getItem('U_status');
if (!role && to.path!='/register'&&to.path!=='/submission'&&to.path!=='/orcidLink'&&to.path!=='/img'&& to.path !=='/reviewer'&&to.path !=='/thanks' &&to.path !== '/login'&&to.path.search(/retrieve/i)<0 ) {
if (!role && to.path!='/register'&&to.path!=='/submission'&&to.path!=='/orcidLink'&&to.path!=='/img'&& to.path !=='/reviewer'&&to.path !=='/thanks' &&to.path !== '/login' &&to.path !== '/managing'&&to.path.search(/retrieve/i)<0 ) {
next('/login');
// } else if (to.meta.permission) {
// // 如果是管理员权限则可进入,这里只是简单的模拟管理员权限而已