瀏覽代碼

feat: 评卷任务结束后手动调用一次获取任务

chenhao 2 年之前
父節點
當前提交
94783c1428
共有 1 個文件被更改,包括 2 次插入2 次删除
  1. 2 2
      src/features/mark/Mark.vue

+ 2 - 2
src/features/mark/Mark.vue

@@ -433,8 +433,6 @@ const saveTaskToServer = async () => {
   if (!res) return;
   // 故意不在此处同步等待,因为不必等待
   updateStatus().catch((e) => console.log("保存任务后获取status出错", e));
-  // 获取下一个任务
-  void nextTask();
   if (res.data.success && store.currentTask) {
     void message.success({ content: "保存成功", key: mkey, duration: 2 });
     if (!store.historyOpen) {
@@ -450,6 +448,8 @@ const saveTaskToServer = async () => {
   } else if (!store.currentTask) {
     void message.warn({ content: "暂无新任务", key: mkey, duration: 10 });
   }
+  // 获取下一个任务
+  void nextTask();
 };
 </script>