diff --git a/src/renderer/src/AixPPTist/src/api/classcourse.ts b/src/renderer/src/AixPPTist/src/api/classcourse.ts
index da4a566..bad9c67 100644
--- a/src/renderer/src/AixPPTist/src/api/classcourse.ts
+++ b/src/renderer/src/AixPPTist/src/api/classcourse.ts
@@ -8,6 +8,7 @@ import * as useStore from '../store' // pptist-状态管理
import ChatWs from '@/plugins/socket' // 聊天socket
import msgUtils from '@/plugins/modal' // 消息工具
+const slidesStore = store.useSlidesStore() // 幻灯片-状态管理
const screenStore = useStore.useScreenStore() // 全屏-状态管理
const classcourseStore = useStore.useClasscourseStore() // 课堂信息-状态管理
const classcourse = sessionStore.get('curr.classcourse') // 课堂信息
@@ -32,10 +33,13 @@ export class Classcourse {
// 连接socket
if (!ChatWs.ws) ChatWs.init()
ChatWs.id = classcourse.timgroupid // 群组id
- console.log('ws- ', classcourse)
this.classcourse = classcourse // 课堂信息
this.id = classcourse.id // 课堂id
- classcourseStore.setClasscourse(classcourse) // 课堂信息-状态管理
+ // 如果课堂信息有paging,则更新当前页码
+ const isPaging = !!classcourse.paging||classcourse.paging==0
+ if (isPaging) slidesStore.updateSlideIndex(classcourse.paging)
+ // 课堂信息-状态管理
+ classcourseStore.setClasscourse(classcourse)
// 待上课提示
if (!classcourse.status) {
this.msgObj = {
diff --git a/src/renderer/src/plugins/imChat/msgEnum.js b/src/renderer/src/plugins/imChat/msgEnum.js
index e921ff6..4b1d56b 100644
--- a/src/renderer/src/plugins/imChat/msgEnum.js
+++ b/src/renderer/src/plugins/imChat/msgEnum.js
@@ -142,4 +142,6 @@ export class MsgEnum {
MSG_0034: 0x0022,
MSG_0035: 0x0023,
}
-}
\ No newline at end of file
+}
+
+export default MsgEnum;
\ No newline at end of file
diff --git a/src/renderer/src/views/classManage/reserv-item-apt.vue b/src/renderer/src/views/classManage/reserv-item-apt.vue
index 18caf2a..67fb1ec 100644
--- a/src/renderer/src/views/classManage/reserv-item-apt.vue
+++ b/src/renderer/src/views/classManage/reserv-item-apt.vue
@@ -14,8 +14,8 @@
上课(APP)
-
+ 继续上课
下课{{ loading?'中...':'' }}
diff --git a/src/renderer/src/views/prepare/container/class-start.vue b/src/renderer/src/views/prepare/container/class-start.vue
index 4d06d5c..c9c518b 100644
--- a/src/renderer/src/views/prepare/container/class-start.vue
+++ b/src/renderer/src/views/prepare/container/class-start.vue
@@ -146,6 +146,7 @@ const open = async (id, classObj) => {
await getAptInfo(id)
// 获取班级列表
getClassList()
+ console.log('classObj', classObj)
// 继续上课
if (!!classObj) {
dt.ctCourse = classObj
@@ -304,11 +305,11 @@ const classTeachingStart = async () => {
const { classcourseid:id } = teacherForm.form
if (id) { // 开始上课
// 新版-pptList 打开公屏
- if (myClassActive.value.filetype == 'aptist') {
+ if (myClassActive.value.filetype == 'aippt') {
const msgEl = ElMessage.warning({message:'正在打开公屏,请稍后...',duration: 0})
setTimeout(async () => {
msgEl.close()
- const res = await Http_Classcourse.getClasscourse(teacherForm.form.classcourseid)
+ const res = await Http_Classcourse.getClasscourse(id)
openPublicScreen(res.data)
}, 2000);
}else {
@@ -316,6 +317,8 @@ const classTeachingStart = async () => {
toLinkWeb(url) // 跳转web-公屏
visible.value = false // 关闭弹窗
}
+ } else {
+ ElMessage.warning('请先创建课程')
}
}
// 获取二维码地址
@@ -354,9 +357,11 @@ const getQrUrl = async() => {
// 打开公屏
const openPublicScreen = (classcourse) => {
console.log('打开公屏', classcourse)
- // 发送app端待开课消息
- const data = { id: classcourse.id }
- ChatWs.sendMsg(MsgEnum.HEADS.MSG_0000, data, {}, ChatWs.TYPES.single, userStore.id)
+ if (!dt.ctCourse) { // 新开课需要发送消息-继续上课不需要直接打开
+ // 发送app端待开课消息
+ const data = { id: classcourse.id }
+ ChatWs.sendMsg(MsgEnum.HEADS.MSG_0000, data, {}, ChatWs.TYPES.single, userStore.id)
+ }
// 缓存当前资源信息
const resource = toRaw(myClassActive.value)
sessionStore.set('curr.resource', resource) // 缓存当前资源信息
diff --git a/src/renderer/src/views/prepare/container/kj-list-item.vue b/src/renderer/src/views/prepare/container/kj-list-item.vue
index 3b6a4c1..0ec8498 100644
--- a/src/renderer/src/views/prepare/container/kj-list-item.vue
+++ b/src/renderer/src/views/prepare/container/kj-list-item.vue
@@ -196,7 +196,7 @@ export default {
}
},*/
clickStartClass(item) {
- const isApt = item.fileFlag === 'apt'
+ const isApt = ['apt','aippt'].includes(item.fileFlag)
this.getOpenCourse(isApt).then(res => {
console.log(res)
if(!res){