| | |
| | | import RightPanel from '@/components/RightPanel' |
| | | import Settings from '../components/Settings/index' |
| | | import * as signalR from '@aspnet/signalr' |
| | | import { ButtonData } from '@/api/basicSettings' |
| | | import Vue from 'vue' |
| | | |
| | | export default { |
| | | components: { |
| | |
| | | // this.$signalr.start() |
| | | this.usercode = getCookie('navTabId') |
| | | this.username = getCookie('username') |
| | | this.stu_torgname = getCookie('stu_torgname') === '' ? '系统管理员' : getCookie('stu_torgname') |
| | | this.stu_torgname = getCookie('stu_torgname') |
| | | }, |
| | | mounted() { |
| | | this.getHubConnectionBuilder() |
| | | // this.getHubConnectionBuilder() |
| | | |
| | | Vue.prototype.$ButtonData = JSON.parse(sessionStorage.getItem('ButtonData')) |
| | | }, |
| | | computed: { |
| | | ...mapGetters([ |
| | |
| | | this.$store.dispatch('app/toggleSideBar') |
| | | }, |
| | | async logout() { |
| | | localStorage.removeItem('token') |
| | | await this.signalr.stop() |
| | | this.signalr.off('SendCustomUserMessage') |
| | | // await this.signalr.stop() |
| | | // this.signalr.off('SendCustomUserMessage') |
| | | await this.$store.dispatch('user/logout') |
| | | this.$message.success('退出成功!') |
| | | localStorage.removeItem('token') |
| | | this.$notify.success('退出成功!') |
| | | this.$router.push(`/login`) |
| | | }, |
| | | editPassword() { |