1
continuous-integration/drone/push Build is passing Details

has
wangxiaoshuang 2026-05-15 17:01:08 +08:00
parent d34b4b796c
commit 730a375509
3 changed files with 187 additions and 149 deletions

View File

@ -1,5 +1,5 @@
<template> <template>
<div id="app" style="position: relative"> <div id="app" style="position: relative" :class="{ mask: isLock }">
<router-view /> <router-view />
<div v-show="show" v-if="$route.matched.length > 0" v-adaptive @click="openI18n" style=" <div v-show="show" v-if="$route.matched.length > 0" v-adaptive @click="openI18n" style="
position: fixed; position: fixed;
@ -97,6 +97,7 @@ import feedBack from '@/views/trials/trials-layout/components/feedBack'
import timeTag from '@/components/timeTag' import timeTag from '@/components/timeTag'
import Vue from 'vue' import Vue from 'vue'
import i18n from './lang' import i18n from './lang'
import DicomEvent from '@/views/trials/trials-panel/reading/dicoms/components/DicomEvent'
export default { export default {
name: 'App', name: 'App',
components: { components: {
@ -112,12 +113,17 @@ export default {
arr: [], arr: [],
il8nExternal: false, il8nExternal: false,
State: null, State: null,
config: window.config config: window.config,
isLock: false
} }
}, },
mounted() { mounted() {
this.show = process.env.VUE_APP_OSS_PATH === '/test/dist' this.show = process.env.VUE_APP_OSS_PATH === '/test/dist'
Vue.prototype.$openI18n = this.openI18n Vue.prototype.$openI18n = this.openI18n
// this.getIsLock()
// DicomEvent.$on("isLock", (isLock) => {
// this.isLock = isLock
// })
}, },
// watch: { // watch: {
// '$route.query': { // '$route.query': {
@ -149,6 +155,13 @@ export default {
// }, // },
// }, // },
methods: { methods: {
getIsLock() {
if (zzSessionStorage.getItem('isLock') === 'true') {
this.isLock = true
} else {
this.isLock = false
}
},
// //
handleSortByColumn(column) { handleSortByColumn(column) {
const { prop, order } = column const { prop, order } = column
@ -307,6 +320,23 @@ export default {
</script> </script>
<style lang="scss"> <style lang="scss">
.mask {
position: relative;
filter: blur(2px);
user-select: none;
}
.mask::after {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
content: '';
display: block;
background: rgba(255, 253, 253, 0.2);
}
$light_gray: #606266; $light_gray: #606266;
.el-tooltip__popper { .el-tooltip__popper {

View File

@ -1,5 +1,6 @@
import Vue from 'vue' import Vue from 'vue'
// import DicomEvent from '@/views/trials/trials-panel/reading/dicoms/components/DicomEvent'
import 'normalize.css/normalize.css' // A modern alternative to CSS resets import 'normalize.css/normalize.css' // A modern alternative to CSS resets
// import { createVersionPolling } from "@/utils/version-polling.esm.js"; // import { createVersionPolling } from "@/utils/version-polling.esm.js";
import ElementUI, { MessageBox } from 'element-ui' import ElementUI, { MessageBox } from 'element-ui'
@ -451,6 +452,7 @@ async function VueInit() {
isOpen = false isOpen = false
isLock = null isLock = null
zzSessionStorage.removeItem('isLock') zzSessionStorage.removeItem('isLock')
// DicomEvent.$emit('isLock', false)
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!', {
@ -462,7 +464,8 @@ async function VueInit() {
}) })
} : () => { }, process.env.VUE_APP_LOGOUT_FOR_TIME, } : () => { }, process.env.VUE_APP_LOGOUT_FOR_TIME,
eval(process.env.VUE_APP_LOCK_FOR_PERMISSION) ? () => { eval(process.env.VUE_APP_LOCK_FOR_PERMISSION)
? () => {
var lang = zzSessionStorage.getItem('lang') ? zzSessionStorage.getItem('lang') : 'zh' var lang = zzSessionStorage.getItem('lang') ? zzSessionStorage.getItem('lang') : 'zh'
if (_vm.$store.state.trials.unlock || WHITELIST.includes(_vm.$route.path)) { if (_vm.$store.state.trials.unlock || WHITELIST.includes(_vm.$route.path)) {
count = 0; count = 0;
@ -470,6 +473,7 @@ async function VueInit() {
if (_vm.$route.path === '/login') { if (_vm.$route.path === '/login') {
zzSessionStorage.removeItem('lastWorkbench') zzSessionStorage.removeItem('lastWorkbench')
zzSessionStorage.removeItem('isLock') zzSessionStorage.removeItem('isLock')
// DicomEvent.$emit('isLock', false)
isLock = null isLock = null
} }
return return
@ -479,6 +483,7 @@ async function VueInit() {
} }
isOpen = true isOpen = true
zzSessionStorage.setItem('isLock', 'true') zzSessionStorage.setItem('isLock', 'true')
// DicomEvent.$emit('isLock', true)
_vm.$msgbox({ _vm.$msgbox({
title: _vm.$t("env:lock:msgBox:title"), title: _vm.$t("env:lock:msgBox:title"),
confirmButtonText: _vm.$t("env:lock:msgBox:confirmButtonText"), confirmButtonText: _vm.$t("env:lock:msgBox:confirmButtonText"),
@ -510,7 +515,8 @@ async function VueInit() {
isOpen = false isOpen = false
count = 0; count = 0;
isLock = null isLock = null
zzSessionStorage.removeItem('isLock') // zzSessionStorage.removeItem('isLock')
DicomEvent.$emit('isLock', false)
localStorage.setItem('count', '0') localStorage.setItem('count', '0')
document.querySelector('#my_username').value = null document.querySelector('#my_username').value = null
document.querySelector('#my_password').value = null document.querySelector('#my_password').value = null
@ -615,7 +621,9 @@ async function VueInit() {
]) ])
]) ])
}) })
} : () => { }, process.env.VUE_APP_LOCK_FOR_TIME) } : () => { },
process.env.VUE_APP_LOCK_FOR_TIME
)
} }
VueInit() VueInit()
// createVersionPolling({ // createVersionPolling({

View File

@ -189,7 +189,7 @@
</el-form-item> </el-form-item>
<el-form-item :label="$t('trials:sitesList:table:Country')" prop="Country"> <el-form-item :label="$t('trials:sitesList:table:Country')" prop="Country">
<el-select v-model="form.Country" style="width: 100%"> <el-select v-model="form.Country" style="width: 100%">
<el-option v-for="item of $d.SiteCountry" :key="item.id" :label="item.label" :value="item.value" /> <el-option v-for="item of $d.SiteCountry" :key="item.id" :label="item.label" :value="item.label" />
</el-select> </el-select>
</el-form-item> </el-form-item>
<!-- 状态 --> <!-- 状态 -->