perf: 优化站内信点击的问题

This commit is contained in:
ibuler
2021-09-10 13:21:18 +08:00
committed by 老广
parent 48d07b4d6d
commit 4588965a8d
6 changed files with 33 additions and 7 deletions

View File

@@ -775,6 +775,7 @@
}
},
"setting": {
"Radius": "Radius",
"Enable": "启用",
"AuthLimit": "登录限制",
"SMTP": "邮件服务器",

View File

@@ -759,6 +759,7 @@
}
},
"setting": {
"Radius": "Radius",
"Enable": "Enable",
"Perm": "Permission",
"SMTP": "SMTP server",

View File

@@ -19,7 +19,7 @@
v-for="msg of messages"
:key="msg.id"
class="msg-item"
:class="msg.has_read ? 'msg-read' : 'msg-unread'"
:class="msg['has_read'] ? 'msg-read' : 'msg-unread'"
@mouseover="hoverMsgId = msg.id"
@mouseleave="hoverMsgId = ''"
@click="showMsgDetail(msg)"

View File

@@ -458,3 +458,26 @@ a {
.el-table-filter__list-item:hover {
color: $--color-text-primary;
}
//.el-dialog__wrapper {
// display: flex;
// align-items: center;
// justify-content: center;
//}
.el-dialog {
display: flex;
flex-direction: column;
margin:0 !important;
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
max-height: calc(100vh - 30px);
max-width: calc(100vh - 30px);
}
.el-dialog .el-dialog__body {
flex: 1;
overflow: auto;
}

View File

@@ -6,6 +6,7 @@ import { refreshSessionIdAge } from '@/api/users'
import { Message, MessageBox } from 'element-ui'
import store from '@/store'
import axiosRetry from 'axios-retry'
import router from '@/router'
// create an axios instance
const service = axios.create({
@@ -17,13 +18,13 @@ const service = axios.create({
function beforeRequestAddToken(config) {
const csrfToken = getTokenFromCookie()
if (csrfToken) {
// let each request carry token
// ['X-Token'] is a custom headers key
// please modify it according to the actual situation
config.headers['X-CSRFToken'] = csrfToken
}
if (store.getters.currentOrg) {
config.headers['X-JMS-ORG'] = store.getters.currentOrg.id
const queryOrgId = router.currentRoute.query?.oid
const storeOrgId = store.getters.currentOrg?.id
const orgId = queryOrgId || storeOrgId
if (orgId) {
config.headers['X-JMS-ORG'] = orgId
}
}

View File

@@ -1,5 +1,5 @@
<template>
<BaseAuth v-model="value" :title="$t('setting.WecCom')">
<BaseAuth v-model="value" :title="$t('setting.WeCom')">
<GenericCreateUpdateForm v-bind="$data" />
</BaseAuth>
</template>