西海岸-管理后台打开后,新提一个流程、操作一个流程,回到后台管理统计数字有误,缺少刷新,切换菜单也不能刷新
This commit is contained in:
parent
6734eafbdd
commit
09edc0fb05
|
@ -1,8 +1,8 @@
|
||||||
<!--
|
<!--
|
||||||
* @Author: hisense.wuhongjian
|
* @Author: hisense.wuhongjian
|
||||||
* @Date: 2022-04-11 10:11:40
|
* @Date: 2022-04-11 10:11:40
|
||||||
* @LastEditors: hisense.wuhongjian
|
* @LastEditors: Light
|
||||||
* @LastEditTime: 2022-08-25 14:51:36
|
* @LastEditTime: 2022-12-29 09:59:52
|
||||||
* @Description: 告诉大家这是什么
|
* @Description: 告诉大家这是什么
|
||||||
-->
|
-->
|
||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
|
@ -39,7 +39,8 @@
|
||||||
window.SITE_CONFIG['previewUrl'] = _global.config.previewUrl;
|
window.SITE_CONFIG['previewUrl'] = _global.config.previewUrl;
|
||||||
window.SITE_CONFIG['apiURL'] = _global.config.apiURL;
|
window.SITE_CONFIG['apiURL'] = _global.config.apiURL;
|
||||||
// WebSocket地址
|
// WebSocket地址
|
||||||
window.SITE_CONFIG['socketURL'] =_global.config.socketURL;
|
// window.SITE_CONFIG['socketURL'] =_global.config.socketURL;
|
||||||
|
window.SITE_CONFIG['websocketURL'] = _global.config.websocketURL
|
||||||
</script>
|
</script>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
|
|
|
@ -105,8 +105,9 @@ import { messages } from '@/i18n'
|
||||||
import screenfull from 'screenfull'
|
import screenfull from 'screenfull'
|
||||||
import UpdatePassword from './main-navbar-update-password'
|
import UpdatePassword from './main-navbar-update-password'
|
||||||
import { clearLoginInfo } from '@/utils'
|
import { clearLoginInfo } from '@/utils'
|
||||||
// import Cookies from 'js-cookie'
|
import Cookies from 'js-cookie'
|
||||||
// var socket = null
|
import bus from '@/views/bus.js'
|
||||||
|
var socket = null
|
||||||
export default {
|
export default {
|
||||||
inject: ['refresh'],
|
inject: ['refresh'],
|
||||||
data () {
|
data () {
|
||||||
|
@ -120,29 +121,38 @@ export default {
|
||||||
UpdatePassword
|
UpdatePassword
|
||||||
},
|
},
|
||||||
created () {
|
created () {
|
||||||
// var vue = this
|
const that = this
|
||||||
// socket = new WebSocket(`${window.SITE_CONFIG['socketURL']}?token=${Cookies.get('token')}`)
|
socket = new WebSocket(`${window.SITE_CONFIG.websocketURL}?token=${Cookies.get('ucsToken')}`)
|
||||||
// socket.onopen = function () {}
|
socket.onopen = function () {}
|
||||||
// socket.onerror = function () {
|
socket.onerror = function () {}
|
||||||
// vue.$notify.error({
|
socket.onmessage = function (res) {
|
||||||
// title: vue.$t('notice.disconnect'),
|
switch (that.$route.name) {
|
||||||
// message: vue.$t('notice.disconnectMessage')
|
case 'myAgent-CompetencyApplication':
|
||||||
// })
|
console.log('websocket,11')
|
||||||
// }
|
bus.$emit('competencyApplicationInit')
|
||||||
// socket.onmessage = function (evt) {
|
break
|
||||||
// const result = JSON.parse(evt.data)
|
case 'myAgent-AbilityResourceShelf':
|
||||||
|
console.log('websocket,22')
|
||||||
// // 如果是有新文本通知,则提示有新通知
|
bus.$emit('abilityResourceShelfInit')
|
||||||
// if (result.type === 0) {
|
break
|
||||||
// vue.messageTip = true
|
case 'myAgent-ApplicationforCompetencyRequirements':
|
||||||
// vue.$notify({
|
console.log('websocket,33')
|
||||||
// title: vue.$t('notice.new'),
|
bus.$emit('applicationforRequirementsInit')
|
||||||
// message: result.msg,
|
break
|
||||||
// type: 'info',
|
case 'myAgent-AbilityResourcesRemoved':
|
||||||
// duration: 5000
|
console.log('websocket,44')
|
||||||
// })
|
bus.$emit('AbilityResourcesRemovedInit')
|
||||||
// }
|
break
|
||||||
// }
|
case 'myAgent-CommentModeration':
|
||||||
|
console.log('websocket,55')
|
||||||
|
bus.$emit('commentInit')
|
||||||
|
break
|
||||||
|
case 'activiti-RoomExamineAdmin':
|
||||||
|
console.log('websocket,66')
|
||||||
|
bus.$emit('roomExamineAdminInit')
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// 未读通知数
|
// 未读通知数
|
||||||
this.getUnReadCount()
|
this.getUnReadCount()
|
||||||
|
|
|
@ -215,6 +215,7 @@
|
||||||
</el-card>
|
</el-card>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
|
import bus from '@/views/bus.js'
|
||||||
import Cookies from 'js-cookie'
|
import Cookies from 'js-cookie'
|
||||||
export default {
|
export default {
|
||||||
data () {
|
data () {
|
||||||
|
@ -248,6 +249,13 @@ export default {
|
||||||
roomNameA: ''
|
roomNameA: ''
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
created () {
|
||||||
|
bus.$off('roomExamineAdminInit')
|
||||||
|
bus.$on('roomExamineAdminInit', () => {
|
||||||
|
this.getSerach()
|
||||||
|
bus.$emit('updateTaskNum')
|
||||||
|
})
|
||||||
|
},
|
||||||
mounted () {
|
mounted () {
|
||||||
this.getSerach()
|
this.getSerach()
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in New Issue