fix(teacher): 使用路由参数替代本地变量获取任务数据
修复学生记录页面中任务数据获取方式,从使用本地变量改为从路由参数获取,确保数据一致性
Showing
1 changed file
with
5 additions
and
5 deletions
| 1 | <!-- | 1 | <!-- |
| 2 | * @Date: 2025-11-19 22:05:00 | 2 | * @Date: 2025-11-19 22:05:00 |
| 3 | * @LastEditors: hookehuyr hookehuyr@gmail.com | 3 | * @LastEditors: hookehuyr hookehuyr@gmail.com |
| 4 | - * @LastEditTime: 2025-12-12 21:26:17 | 4 | + * @LastEditTime: 2025-12-13 21:42:55 |
| 5 | * @FilePath: /mlaj/src/views/teacher/studentRecordPage.vue | 5 | * @FilePath: /mlaj/src/views/teacher/studentRecordPage.vue |
| 6 | * @Description: 学生作业记录页面(仅作业记录与点评功能),固定 user_id 与 group_id | 6 | * @Description: 学生作业记录页面(仅作业记录与点评功能),固定 user_id 与 group_id |
| 7 | --> | 7 | --> |
| ... | @@ -247,12 +247,12 @@ function handleAudioPlay(id) { | ... | @@ -247,12 +247,12 @@ function handleAudioPlay(id) { |
| 247 | async function onLoad() { | 247 | async function onLoad() { |
| 248 | const nextPage = page.value | 248 | const nextPage = page.value |
| 249 | const res = await getCheckinTeacherListAPI({ | 249 | const res = await getCheckinTeacherListAPI({ |
| 250 | - task_id: task_id.value, | 250 | + task_id: $route.query.task_id, |
| 251 | - subtask_id: selectedSubtaskId.value, | 251 | + subtask_id: $route.query.subtask_id, |
| 252 | limit: limit.value, | 252 | limit: limit.value, |
| 253 | page: nextPage, | 253 | page: nextPage, |
| 254 | - created_by: created_by.value, | 254 | + created_by: $route.query.created_by, |
| 255 | - date: date.value, | 255 | + date: $route.query.date, |
| 256 | }) | 256 | }) |
| 257 | if (res.code) { | 257 | if (res.code) { |
| 258 | checkinDataList.value = [...checkinDataList.value, ...formatData(res.data.checkin_list)] | 258 | checkinDataList.value = [...checkinDataList.value, ...formatData(res.data.checkin_list)] | ... | ... |
-
Please register or login to post a comment