Commit 08e7f7e2 by 潘诗林

feat: 返回员工学习情况

1 parent 72c0e7d7
...@@ -11,6 +11,7 @@ import lombok.Getter; ...@@ -11,6 +11,7 @@ import lombok.Getter;
public enum PreLearnStatusEnum { public enum PreLearnStatusEnum {
NOT_STUDY(0, "未学习"), NOT_STUDY(0, "未学习"),
STUDIED(1, "已学习"), STUDIED(1, "已学习"),
ALL_STUDIED(2,"全部案例已学习")
; ;
private final int value; private final int value;
......
...@@ -267,6 +267,8 @@ public class PreLearnStaffService { ...@@ -267,6 +267,8 @@ public class PreLearnStaffService {
staffUuid, activityProductId); staffUuid, activityProductId);
if (readCaseIds == null) { if (readCaseIds == null) {
readCaseIds = Collections.emptyList(); readCaseIds = Collections.emptyList();
}else {
resp.setStaffLearnStatus(PreLearnStatusEnum.STUDIED.getValue());
} }
//如果员工已经把生成好的案例学习完了 还有未生成的则为生成中 //如果员工已经把生成好的案例学习完了 还有未生成的则为生成中
if(readyScript.size() == readCaseIds.size()){ if(readyScript.size() == readCaseIds.size()){
...@@ -274,7 +276,7 @@ public class PreLearnStaffService { ...@@ -274,7 +276,7 @@ public class PreLearnStaffService {
resp.setAiStatus(AiStatusEnum.GENERATING.getValue()); resp.setAiStatus(AiStatusEnum.GENERATING.getValue());
}else { }else {
//生成的为空表示已学习完毕 //生成的为空表示已学习完毕
resp.setStaffLearnStatus(PreLearnStatusEnum.STUDIED.getValue()); resp.setStaffLearnStatus(PreLearnStatusEnum.ALL_STUDIED.getValue());
} }
return resp; return resp;
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!