|
|
|
@ -129,12 +129,20 @@ public class TerminalPhotoController extends BaseController {
|
|
|
|
|
@ApiResponses({@ApiResponse(code = 200, message = "请求成功"), @ApiResponse(code = 400, message = "请求参数没填好"), @ApiResponse(code = 404, message = "请求路径没有或页面跳转路径不对")})
|
|
|
|
|
@RequestMapping("/getTakePicPhotoStatus")
|
|
|
|
|
@Log(title = "主动拍照下照片状态查询", type = "查询")
|
|
|
|
|
public ResponseReult<Boolean> getTakePicPhotoStatus(@Validated ReturnedPhotoVo vo) {
|
|
|
|
|
ServiceBody<Boolean> serviceBody = terminalPhotoService.getTakePicPhotoStatus(vo);
|
|
|
|
|
if (serviceBody.getCode() == ServiceStatus.SUCCESS) {
|
|
|
|
|
return ResponseReult.success(serviceBody.getData());
|
|
|
|
|
} else {
|
|
|
|
|
return ResponseReult.error(serviceBody.getCode(), serviceBody.getMsg());
|
|
|
|
|
public ResponseReult<Boolean> getTakePicPhotoStatus( @Validated ReturnedPhotoVo vo) {
|
|
|
|
|
try {
|
|
|
|
|
if (workingMap.containsKey(vo.getRequestid())) {
|
|
|
|
|
throw new ApiException("相同请求正在处理中, 请刷新页面更新");
|
|
|
|
|
}
|
|
|
|
|
workingMap.put(vo.getRequestid(), "1");
|
|
|
|
|
ServiceBody<Boolean> serviceBody = terminalPhotoService.getTakePicPhotoStatus(vo);
|
|
|
|
|
if (serviceBody.getCode() == ServiceStatus.SUCCESS) {
|
|
|
|
|
return ResponseReult.success(serviceBody.getData());
|
|
|
|
|
} else {
|
|
|
|
|
return ResponseReult.error(serviceBody.getCode(), serviceBody.getMsg());
|
|
|
|
|
}
|
|
|
|
|
} finally {
|
|
|
|
|
workingMap.remove(vo.getRequestid());
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|