From aca04f37198001100eec8d593545911bfc9cc343 Mon Sep 17 00:00:00 2001 From: yujialong <479214531@qq.com> Date: Thu, 2 Jan 2025 17:44:58 +0800 Subject: [PATCH] fix --- src/layouts/header/index.vue | 4 +- src/pages/backend/list/index.vue | 8 ++- src/pages/expSystem/list/index.vue | 2 +- src/pages/lesson/content/index.vue | 2 +- src/pages/lesson/content/source.vue | 2 +- src/pages/lesson/detail/index.vue | 35 +++++---- src/pages/station/preview/index.vue | 106 +++++++++++++++------------- src/pages/system/list/index.vue | 13 ++-- src/pages/workbench/list/index.vue | 2 +- 9 files changed, 95 insertions(+), 79 deletions(-) diff --git a/src/layouts/header/index.vue b/src/layouts/header/index.vue index 06b387e..40f065c 100644 --- a/src/layouts/header/index.vue +++ b/src/layouts/header/index.vue @@ -131,7 +131,7 @@ export default { }, initSocket ({ id, account }) { // 实例化socket - this.socket = new WebSocket(`${Setting.isTest ? 'ws' : 'wss'}://${Setting.isDev ? '192.168.31.51:9100' : location.host}/nakadai/websocket/${id}/${account}`) + this.socket = new WebSocket(`wss://${Setting.isDev ? '192.168.31.51:9100' : location.host}/nakadai/websocket/${id}/${account}`) // this.socket = new WebSocket(`ws://118.31.167.228:9100/nakadai/websocket/${id}/${account}`) // 监听socket连接 this.socket.onopen = this.open; @@ -163,7 +163,6 @@ export default { }, getUserDetail () { // 获取用户详情 this.$get(this.api.queryUserInfoDetails).then(res => { - this.initSocket(res.result.userAccount) let { hrUserInfo } = res.result if (hrUserInfo) { const { userAvatars, userName, userId } = hrUserInfo @@ -172,6 +171,7 @@ export default { console.log("🚀 ~ this.$get ~ userAvatars:", userName) this.setUserName(userName) } + this.initSocket(res.result.userAccount) }).catch(res => { }) }, userCommand (command) { // 切换下拉菜单 diff --git a/src/pages/backend/list/index.vue b/src/pages/backend/list/index.vue index 5d0a42d..4690ead 100644 --- a/src/pages/backend/list/index.vue +++ b/src/pages/backend/list/index.vue @@ -25,7 +25,7 @@ export default { }, data () { return { - active: 'tab1', + active: this.$route.query.type || 'tab1', tabs: { tab1: '学生管理', tab2: '实验系统管理', @@ -45,6 +45,12 @@ export default { methods: { tabChange (index) { this.active = index + this.$router.push({ + path: 'list', + query: { + type: index + } + }) }, initTabs () { const { btns } = this diff --git a/src/pages/expSystem/list/index.vue b/src/pages/expSystem/list/index.vue index 4a5e9f4..7b7089e 100644 --- a/src/pages/expSystem/list/index.vue +++ b/src/pages/expSystem/list/index.vue @@ -155,7 +155,7 @@ export default { if (row.systemId == 19) { location.href = `${Setting.sandPath}/#/config?token=${this.token}&referrer=${encodeURIComponent(location.href)}` } else { - this.$router.push(`backstage?systemId=${row.systemId}&show=1&name=${row.systemName}`) + this.$router.push(`/expSystem/backstage?systemId=${row.systemId}&show=1&name=${row.systemName}`) } }, } diff --git a/src/pages/lesson/content/index.vue b/src/pages/lesson/content/index.vue index 08d4e0d..f7e9504 100644 --- a/src/pages/lesson/content/index.vue +++ b/src/pages/lesson/content/index.vue @@ -447,7 +447,7 @@ export default { ] this.moveVisible = true } else { - this.$message.warning('请选择小节!') + this.$message.warning('请选择资源!') } }, // 批量移除小节 diff --git a/src/pages/lesson/content/source.vue b/src/pages/lesson/content/source.vue index 5b1fd93..0338066 100644 --- a/src/pages/lesson/content/source.vue +++ b/src/pages/lesson/content/source.vue @@ -20,7 +20,7 @@ @click="course.shrink = !course.shrink"> - {{ course.curriculumName }} + {{ course.curriculumName || course.courseName }}
diff --git a/src/pages/lesson/detail/index.vue b/src/pages/lesson/detail/index.vue index b500df1..41b9aa6 100644 --- a/src/pages/lesson/detail/index.vue +++ b/src/pages/lesson/detail/index.vue @@ -80,8 +80,8 @@
+ :on-error="uploadError" :before-remove="beforeRemove" :limit="10000" :file-list="fileList" + :on-exceed="handleExceed" action="" :http-request="handleRequest">

将图片拖到此处,或点击上传

@@ -225,7 +225,7 @@
  • - +
    {{ item.label }} @@ -234,7 +234,7 @@
    - +
    {{ system.systemName }} @@ -269,8 +269,7 @@ 批量移除
    - +