|
|
@@ -6,6 +6,7 @@ import com.izouma.nineth.dto.PageQuery;
|
|
|
import com.izouma.nineth.enums.MetaTaskStatus;
|
|
|
import com.izouma.nineth.repo.MetaTaskToUserNewRepo;
|
|
|
import com.izouma.nineth.service.MetaTaskToUserNewService;
|
|
|
+import com.izouma.nineth.utils.SecurityUtils;
|
|
|
import com.izouma.nineth.utils.excel.ExcelUtils;
|
|
|
import lombok.AllArgsConstructor;
|
|
|
import org.springframework.data.domain.Page;
|
|
|
@@ -39,11 +40,11 @@ public class MetaTaskToUserNewController {
|
|
|
return metaTaskToUserNewService.receiveTask(metaTaskToUserNew, true);
|
|
|
}
|
|
|
|
|
|
- @GetMapping("/{id}/findProgress")
|
|
|
- public MetaRestResult<MetaTaskToUserNew> findProgress(@PathVariable Long id) {
|
|
|
- MetaTaskToUserNew metaTaskToUserNew = metaTaskToUserNewRepo.findByIdAndDel(id, false);
|
|
|
+ @GetMapping("/{taskId}/{atomTaskId}/findProgress")
|
|
|
+ public MetaRestResult<MetaTaskToUserNew> findProgress(@PathVariable Long taskId, @PathVariable Long atomTaskId) {
|
|
|
+ MetaTaskToUserNew metaTaskToUserNew = metaTaskToUserNewRepo.findByUserIdAndTaskIdAndAtomTaskIdAndDel(SecurityUtils.getAuthenticatedUser().getId(), taskId, atomTaskId, false);
|
|
|
if (Objects.isNull(metaTaskToUserNew)) {
|
|
|
- return MetaRestResult.returnError(String.format("根据id[%S]查询不到用户领取记录", id));
|
|
|
+ return MetaRestResult.returnError(String.format("根据任务id[%S]+基础任务id[%S]查询不到用户领取记录", taskId, atomTaskId));
|
|
|
}
|
|
|
return metaTaskToUserNewService.setSingleProgress(metaTaskToUserNew);
|
|
|
}
|