无法上课PPT的问题解决
This commit is contained in:
parent
540229cd9b
commit
ec8f7b5727
|
@ -10,12 +10,12 @@
|
||||||
<li class="flex" :class="[activeId == menu.path ? 'active-li' : '', menu.disabled ? 'disabled' : '']"
|
<li class="flex" :class="[activeId == menu.path ? 'active-li' : '', menu.disabled ? 'disabled' : '']"
|
||||||
v-for="menu in headerMenus" :key="menu.id" @click="clickMenu(menu)">
|
v-for="menu in headerMenus" :key="menu.id" @click="clickMenu(menu)">
|
||||||
<div class="icon-box">
|
<div class="icon-box">
|
||||||
|
|
||||||
|
|
||||||
<svg class="icon iconfont" aria-hidden="true">
|
<svg class="icon iconfont" aria-hidden="true">
|
||||||
<use :xlink:href="menu.icon"></use>
|
<use :xlink:href="menu.icon"></use>
|
||||||
</svg>
|
</svg>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<span class="text">{{ menu.name }}</span>
|
<span class="text">{{ menu.name }}</span>
|
||||||
</li>
|
</li>
|
||||||
|
@ -80,8 +80,8 @@ import { updateUserInfo } from '@/api/system/user'
|
||||||
import logoIco from '@/assets/images/logo.png'
|
import logoIco from '@/assets/images/logo.png'
|
||||||
import { listEvaluation } from '@/api/classManage/index'
|
import { listEvaluation } from '@/api/classManage/index'
|
||||||
import { sessionStore } from '@/utils/store'
|
import { sessionStore } from '@/utils/store'
|
||||||
import Chat from '@/utils/chat' // im 登录初始化
|
// import Chat from '@/utils/chat' // im 登录初始化
|
||||||
if (!Chat.imChat) Chat.init()
|
// if (!Chat.imChat) Chat.init()
|
||||||
|
|
||||||
let homeTitle = ref(import.meta.env.VITE_APP_TITLE)
|
let homeTitle = ref(import.meta.env.VITE_APP_TITLE)
|
||||||
const { ipcRenderer } = window.electron || {}
|
const { ipcRenderer } = window.electron || {}
|
||||||
|
@ -145,7 +145,7 @@ function handleCommand(command) {
|
||||||
break
|
break
|
||||||
case 'logout':
|
case 'logout':
|
||||||
logout()
|
logout()
|
||||||
Chat?.logout() // im 退出登录
|
// Chat?.logout() // im 退出登录
|
||||||
break
|
break
|
||||||
default:
|
default:
|
||||||
break
|
break
|
||||||
|
@ -161,7 +161,9 @@ function logout() {
|
||||||
cancelButtonText: '取消',
|
cancelButtonText: '取消',
|
||||||
type: 'warning'
|
type: 'warning'
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(async () => {
|
||||||
|
const Chat = (await import('@/utils/chat')).default
|
||||||
|
if (!!Chat.imChat) Chat.logout()
|
||||||
userStore
|
userStore
|
||||||
.logOut()
|
.logOut()
|
||||||
.then(() => {
|
.then(() => {
|
||||||
|
@ -172,8 +174,7 @@ function logout() {
|
||||||
// router.replace('/login')
|
// router.replace('/login')
|
||||||
ipcRenderer && ipcRenderer.send('openLoginWindow')
|
ipcRenderer && ipcRenderer.send('openLoginWindow')
|
||||||
})
|
})
|
||||||
})
|
}).catch(()=>{})
|
||||||
.catch(() => { })
|
|
||||||
}
|
}
|
||||||
|
|
||||||
const emits = defineEmits(['setLayout'])
|
const emits = defineEmits(['setLayout'])
|
||||||
|
@ -183,10 +184,10 @@ function setLayout() {
|
||||||
// 切换学科
|
// 切换学科
|
||||||
const changeSubject = async (command) =>{
|
const changeSubject = async (command) =>{
|
||||||
let sessionSubject = {
|
let sessionSubject = {
|
||||||
bookList: null,
|
bookList: null,
|
||||||
curBook: null,
|
curBook: null,
|
||||||
curNode: null,
|
curNode: null,
|
||||||
defaultExpandedKeys: [],
|
defaultExpandedKeys: [],
|
||||||
subjectTree: []
|
subjectTree: []
|
||||||
}
|
}
|
||||||
sessionStore.set( 'subject', sessionSubject)
|
sessionStore.set( 'subject', sessionSubject)
|
||||||
|
|
|
@ -20,9 +20,9 @@ export class Chat {
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* 初始化 获取IM签名
|
* 初始化 获取IM签名
|
||||||
* @param {*} isInit : 是否初始化IM
|
* @param {*} isInit : 是否初始化IM
|
||||||
* @param {*} isLogin : 是否登录IM
|
* @param {*} isLogin : 是否登录IM
|
||||||
* @param {*} callback: 监听消息回调函数
|
* @param {*} callback: 监听消息回调函数
|
||||||
* @returns Promise<ImChat>
|
* @returns Promise<ImChat>
|
||||||
*/
|
*/
|
||||||
async init(isInit = true, isLogin = true, callback) {
|
async init(isInit = true, isLogin = true, callback) {
|
||||||
|
@ -69,7 +69,6 @@ export class Chat {
|
||||||
async logout() {
|
async logout() {
|
||||||
if (!this.imChat) return
|
if (!this.imChat) return
|
||||||
await this.imChat?.logout()
|
await this.imChat?.logout()
|
||||||
imChat = null
|
|
||||||
this.imChat = null
|
this.imChat = null
|
||||||
}
|
}
|
||||||
// 发群消息
|
// 发群消息
|
||||||
|
@ -95,4 +94,4 @@ export class Chat {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
export default new Chat()
|
export default new Chat()
|
||||||
|
|
Loading…
Reference in New Issue