定时锁定功能问题修复
continuous-integration/drone/push Build is running
Details
continuous-integration/drone/push Build is running
Details
parent
a53fc5478b
commit
d5f1ecbb04
25
src/main.js
25
src/main.js
|
@ -361,8 +361,12 @@ async function VueInit() {
|
||||||
}
|
}
|
||||||
const h = _vm.$createElement
|
const h = _vm.$createElement
|
||||||
/* eslint-disable */
|
/* eslint-disable */
|
||||||
|
// eval(process.env.VUE_APP_LOGOUT_FOR_PERMISSION)
|
||||||
|
// process.env.VUE_APP_LOGOUT_FOR_TIME
|
||||||
|
// eval(process.env.VUE_APP_LOCK_FOR_PERMISSION)
|
||||||
|
// process.env.VUE_APP_LOCK_FOR_TIME
|
||||||
window.VUE_APP_COMPANY_NAME = process.env.VUE_APP_COMPANY_NAME;
|
window.VUE_APP_COMPANY_NAME = process.env.VUE_APP_COMPANY_NAME;
|
||||||
waitOperate(eval(process.env.VUE_APP_LOGOUT_FOR_PERMISSION) ? () => {
|
waitOperate(true ? () => {
|
||||||
var lang = zzSessionStorage.getItem('lang') ? zzSessionStorage.getItem('lang') : 'zh'
|
var lang = zzSessionStorage.getItem('lang') ? zzSessionStorage.getItem('lang') : 'zh'
|
||||||
if (_vm.$route.path === '/ReviewersResearchForm' || _vm.$route.path === '/ReviewersResearch' || _vm.$route.path === '/login' || _vm.$route.path === '/researchForm' || _vm.$route.path === '/researchLogin' || _vm.$route.path === '/email-recompose' || _vm.$route.path === '/recompose' || _vm.$route.path === '/resetpassword' || _vm.$route.path === '/error') {
|
if (_vm.$route.path === '/ReviewersResearchForm' || _vm.$route.path === '/ReviewersResearch' || _vm.$route.path === '/login' || _vm.$route.path === '/researchForm' || _vm.$route.path === '/researchLogin' || _vm.$route.path === '/email-recompose' || _vm.$route.path === '/recompose' || _vm.$route.path === '/resetpassword' || _vm.$route.path === '/error') {
|
||||||
count = 0;
|
count = 0;
|
||||||
|
@ -371,6 +375,19 @@ async function VueInit() {
|
||||||
}
|
}
|
||||||
_vm.$store.dispatch('user/logout').then(res => {
|
_vm.$store.dispatch('user/logout').then(res => {
|
||||||
// window.location.href = `/login`
|
// window.location.href = `/login`
|
||||||
|
let dom = document.querySelectorAll('.el-message-box__wrapper');
|
||||||
|
for (let i = 0; i < dom.length; i++) {
|
||||||
|
let item = dom[i];
|
||||||
|
let title = item.getAttribute("aria-label");
|
||||||
|
if (title === '已锁定' || title === 'Locked') {
|
||||||
|
document.body.removeChild(item);
|
||||||
|
let modal = document.querySelectorAll('.v-modal');
|
||||||
|
for (let i = 0; i < modal.length; i++) {
|
||||||
|
let m = modal[i];
|
||||||
|
document.body.removeChild(m);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
router.push("/login")
|
router.push("/login")
|
||||||
}).then(() => {
|
}).then(() => {
|
||||||
_vm.$alert(lang === 'zh' ? '由于您长时间未操作,为保护您的数据安全已强制将您下线,如果需要继续操作请重新登陆!' : 'No operation for a long time non-operation, you have been forced logout to protect data security. If continue to operate, please login again!', {
|
_vm.$alert(lang === 'zh' ? '由于您长时间未操作,为保护您的数据安全已强制将您下线,如果需要继续操作请重新登陆!' : 'No operation for a long time non-operation, you have been forced logout to protect data security. If continue to operate, please login again!', {
|
||||||
|
@ -378,8 +395,8 @@ async function VueInit() {
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
|
||||||
} : () => { }, process.env.VUE_APP_LOGOUT_FOR_TIME,
|
} : () => { }, 20,
|
||||||
eval(process.env.VUE_APP_LOCK_FOR_PERMISSION) ? () => {
|
true ? () => {
|
||||||
var lang = zzSessionStorage.getItem('lang') ? zzSessionStorage.getItem('lang') : 'zh'
|
var lang = zzSessionStorage.getItem('lang') ? zzSessionStorage.getItem('lang') : 'zh'
|
||||||
if (_vm.$route.path === '/ReviewersResearchForm' || _vm.$route.path === '/ReviewersResearch' || _vm.$route.path === '/login' || _vm.$route.path === '/researchForm' || _vm.$route.path === '/researchLogin' || _vm.$route.path === '/email-recompose' || _vm.$route.path === '/recompose' || _vm.$route.path === '/resetpassword' || _vm.$route.path === '/error') {
|
if (_vm.$route.path === '/ReviewersResearchForm' || _vm.$route.path === '/ReviewersResearch' || _vm.$route.path === '/login' || _vm.$route.path === '/researchForm' || _vm.$route.path === '/researchLogin' || _vm.$route.path === '/email-recompose' || _vm.$route.path === '/recompose' || _vm.$route.path === '/resetpassword' || _vm.$route.path === '/error') {
|
||||||
count = 0;
|
count = 0;
|
||||||
|
@ -509,7 +526,7 @@ async function VueInit() {
|
||||||
])
|
])
|
||||||
])
|
])
|
||||||
})
|
})
|
||||||
} : () => { }, process.env.VUE_APP_LOCK_FOR_TIME)
|
} : () => { }, 10)
|
||||||
}
|
}
|
||||||
VueInit()
|
VueInit()
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue