This commit is contained in:
杨航
2025-09-08 09:30:02 +08:00
parent 4572d6856c
commit 97e0923947
+12 -3
View File
@@ -163,6 +163,7 @@ const { statusBarHeight } = uni.getWindowInfo()
const pageTopPadding = computed(() => statusBarHeight + 'px') const pageTopPadding = computed(() => statusBarHeight + 'px')
const isContinue = ref('N')
// 初始化数据 // 初始化数据
const getData = async flag => { const getData = async flag => {
try { try {
@@ -199,12 +200,14 @@ const getData = async flag => {
// 继续学习 获取学习历史接口 // 继续学习 获取学习历史接口
// 滚动到最下面 // 滚动到最下面
scrollToBottomNow() scrollToBottomNow()
isContinue.value = "Y"
sendMessage({ sendMessage({
commond: 'STDY', commond: 'STDY',
body: { body: {
crsId: crsId.value, crsId: crsId.value,
teacherNo: choiceTeacher.value, teacherNo: choiceTeacher.value,
studyType: isPreview.value ? 'P' : 'S' studyType: isPreview.value ? 'P' : 'S',
isContinue: isContinue.value
} }
}) })
step.value = 2 step.value = 2
@@ -361,13 +364,16 @@ const canAnswerText = computed(() => {
return '每个问题最多连续发送五次答案!' return '每个问题最多连续发送五次答案!'
}) })
const oldStdyId = ref('')
// 获取段落 // 获取段落
const getGraphInfoUnStudy = (flag = 0) => { const getGraphInfoUnStudy = (flag = 0) => {
let _id = new Date().getTime() + 'id' let _id = new Date().getTime() + 'id'
let _data = { let _data = {
crsId: crsId.value, crsId: crsId.value,
stdyId: unref(stdyId), stdyId: unref(stdyId),
stdyBatch: unref(stdyBatch) stdyBatch: unref(stdyBatch),
oldStdyId: unref(oldStdyId),
isContinue: isContinue.value
} }
if (flag === 1 && !!startPgrphId.value) { if (flag === 1 && !!startPgrphId.value) {
_data.pgrphId = startPgrphId.value _data.pgrphId = startPgrphId.value
@@ -510,7 +516,9 @@ const nextQuestionSuccess = (info, type = 'next') => {
requestBody: JSON.stringify({ requestBody: JSON.stringify({
stdyId: unref(stdyId), stdyId: unref(stdyId),
pgrphId: info?.pgrphId, pgrphId: info?.pgrphId,
logId: info?.logId logId: info?.logId,
oldStdyId: unref(oldStdyId),
isContinue: isContinue.value
}) })
}).then(res => { }).then(res => {
talkingList.value.push({ talkingList.value.push({
@@ -659,6 +667,7 @@ const initsocketTask = () => {
if (commond === 'STDYBTH' && !stdyId.value) { if (commond === 'STDYBTH' && !stdyId.value) {
stdyId.value = body.stdyId || '' stdyId.value = body.stdyId || ''
stdyBatch.value = body.stdyBatch || '' stdyBatch.value = body.stdyBatch || ''
oldStdyId.value = body.oldStdyId || ''
logId.value = body.logId || '' logId.value = body.logId || ''
getGraphInfoUnStudy(1) getGraphInfoUnStudy(1)
step.value = 2 step.value = 2