提交 d4aa30be authored 作者: douxy's avatar douxy

CP计划小程序改造,修改下班打卡验证

上级 097c1401
...@@ -139,26 +139,23 @@ public class TemporaryActivityCoreController { ...@@ -139,26 +139,23 @@ public class TemporaryActivityCoreController {
@PutMapping("/reported/approve/submit/{id}") @PutMapping("/reported/approve/submit/{id}")
public R activityReportedSubmit(@PathVariable("id") Long id) { public R activityReportedSubmit(@PathVariable("id") Long id) {
TemporaryActivityReportedDto activityReportedDto = temporaryActivityQueryService.findTemporaryActivityById(id); TemporaryActivityReportedDto activityReportedDto = temporaryActivityQueryService.findTemporaryActivityById(id);
Boolean posFlag = CollectionUtils.isEmpty(activityReportedDto.getPosTaskClockPhotoUrls())|| activityReportedDto.getPosTaskClockPhotoUrls().size() < 1;
if (activityReportedDto.getApproveStatus().equals(TemActApproveStatus.APPROVED) ){ if (CollectionUtils.isEmpty(activityReportedDto.getTgscPhotoInfos()) ){
if (posFlag) {
return R.fail(RCode.NOT_POS_TASK_PHOTO_ERROR);
}
return R.success();
}else{
if (CollectionUtils.isEmpty(activityReportedDto.getTgscPhotoInfos()) || activityReportedDto.getTgscPhotoInfos().size() < 2){
throw new DataException(RCode.NOT_TGSH_PHOTO_ERROR); throw new DataException(RCode.NOT_TGSH_PHOTO_ERROR);
}else if (CollectionUtils.isEmpty(activityReportedDto.getTghdPhotoInfos()) || activityReportedDto.getTghdPhotoInfos().size() < 2){ }else if (CollectionUtils.isEmpty(activityReportedDto.getTghdPhotoInfos()) ){
throw new DataException(RCode.NOT_TGHD_PHOTO_ERROR); throw new DataException(RCode.NOT_TGHD_PHOTO_ERROR);
}else if (CollectionUtils.isEmpty(activityReportedDto.getTgcjPhotoInfos()) || activityReportedDto.getTgcjPhotoInfos().size() < 2){ }else if (CollectionUtils.isEmpty(activityReportedDto.getTgcjPhotoInfos()) ){
throw new DataException(RCode.NOT_TGCJ_PHOTO_ERROR); throw new DataException(RCode.NOT_TGCJ_PHOTO_ERROR);
}else if (CollectionUtils.isEmpty(activityReportedDto.getScpPhotoUrls()) ){
throw new DataException(RCode.NOT_SCP_PHOTO_ERROR);
} else if (CollectionUtils.isEmpty(activityReportedDto.getPfzpPhotoUrls()) ){
throw new DataException(RCode.NOT_PFZP_PHOTO_ERROR);
} else if (CollectionUtils.isEmpty(activityReportedDto.getGfqPhotoUrls()) ){
throw new DataException(RCode.NOT_GFQ_PHOTO_ERROR);
} else if (CollectionUtils.isEmpty(activityReportedDto.getScbbwlPhotoUrls()) ){
throw new DataException(RCode.NOT_SCBBWL_PHOTO_ERROR);
} }
tempActivityCoreService.activityReportedSubmit(id); tempActivityCoreService.activityReportedSubmit(id);
if (posFlag) {
return R.fail(RCode.NOT_POS_TASK_PHOTO_ERROR);
}
}
return R.success(); return R.success();
} }
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论