feat: Implement 'My Courses' dashboard, including course cards, classroom learning, and quiz pages.
This commit is contained in:
parent
fc3e2820cc
commit
f6bbd60f2b
5 changed files with 111 additions and 74 deletions
|
|
@ -50,13 +50,18 @@ const submitQuiz = (auto = false) => {
|
|||
}
|
||||
}
|
||||
|
||||
const route = useRoute()
|
||||
|
||||
const confirmExit = () => {
|
||||
const courseId = route.query.course_id
|
||||
const target = courseId ? `/classroom/learning?course_id=${courseId}` : '/classroom/learning'
|
||||
|
||||
if (currentScreen.value === 'taking') {
|
||||
if (confirm('คุณกำลังทำแบบทดสอบอยู่ หากออกตอนนี้ความคืบหน้าจะหายไป ยืนยันที่จะออก?')) {
|
||||
router.push('/classroom/learning')
|
||||
router.push(target)
|
||||
}
|
||||
} else {
|
||||
router.push('/classroom/learning')
|
||||
router.push(target)
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue