fix: 完成任务后更新选中项的状态
在任务打卡成功时,将选中项的 is_gray 和 is_finish 状态设置为 true,以正确反映任务完成状态
Showing
1 changed file
with
2 additions
and
0 deletions
| ... | @@ -219,6 +219,8 @@ const handle_submit = async () => { | ... | @@ -219,6 +219,8 @@ const handle_submit = async () => { |
| 219 | try { | 219 | try { |
| 220 | const { code } = await checkinTaskAPI({ subtask_id }) | 220 | const { code } = await checkinTaskAPI({ subtask_id }) |
| 221 | if (code === 1) { | 221 | if (code === 1) { |
| 222 | + selected_item.value.is_gray = true | ||
| 223 | + selected_item.value.is_finish = true | ||
| 222 | emit('submit-success') | 224 | emit('submit-success') |
| 223 | showToast('打卡成功') | 225 | showToast('打卡成功') |
| 224 | selected_item.value = null | 226 | selected_item.value = null | ... | ... |
-
Please register or login to post a comment