Commit 09a2a8a6 by Lin

fix(prelearnBridge): 修复学习状态检查逻辑

- 将学习状态查询的变量作用域调整为局部,确保逻辑清晰。
- 更新了导航逻辑,确保在不同入口源下正确显示提示或返回。
1 parent ffe0e8d1
...@@ -773,16 +773,20 @@ export default { ...@@ -773,16 +773,20 @@ export default {
} }
console.log('this.isMainPush***', this.isMainPush); console.log('this.isMainPush***', this.isMainPush);
// if (Number(this.isMainPush) === 1) { // if (Number(this.isMainPush) === 1) {
let learned = false
try { try {
const learned = await this.checkMainPushStaffLearnStatus() learned = await this.checkMainPushStaffLearnStatus()
console.log("学习状态查询***", learned); console.log("学习状态查询***", learned);
} catch (error) {
console.error('[prelearnBridge] 预学习状态查询失败:', error)
}
if (learned) { if (learned) {
this.navigateBack() this.navigateBack()
return return
} }
this.showMainPushBackTip() if (this.prelearnContext.entrySource === 'home_popup') {
} catch (error) { this.showBackPopup = true
console.error('[prelearnBridge] 预学习状态查询失败:', error) } else {
this.showMainPushBackTip() this.showMainPushBackTip()
} }
// } // }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!