주소록 오류 수정
This commit is contained in:
parent
d7bdace043
commit
e6ce8ce036
@ -69,21 +69,32 @@ public class AddrRestController {
|
||||
public ResponseEntity<StatusResponse> addrMassInsertByTempAjax_advc(@RequestBody List<AddrVO> addrListVO
|
||||
,ModelMap model) throws Exception{
|
||||
|
||||
try {
|
||||
|
||||
|
||||
|
||||
LoginVO loginVO = EgovUserDetailsHelper.isAuthenticated()? (LoginVO)EgovUserDetailsHelper.getAuthenticatedUser():null;
|
||||
String userId = loginVO == null ? "" : EgovStringUtil.isNullToString(loginVO.getId());
|
||||
|
||||
if(userId.equals("")) {
|
||||
return ResponseEntity.ok(
|
||||
new StatusResponse(HttpStatus.UNAUTHORIZED
|
||||
, "로그인을 하셔야 이용 가능합니다."
|
||||
, LocalDateTime.now()
|
||||
)
|
||||
);
|
||||
}
|
||||
LoginVO loginVO = EgovUserDetailsHelper.isAuthenticated()? (LoginVO)EgovUserDetailsHelper.getAuthenticatedUser():null;
|
||||
String userId = loginVO == null ? "" : EgovStringUtil.isNullToString(loginVO.getId());
|
||||
|
||||
if(userId.equals("")) {
|
||||
return ResponseEntity.ok(
|
||||
new StatusResponse(HttpStatus.UNAUTHORIZED
|
||||
, "로그인을 하셔야 이용 가능합니다."
|
||||
, LocalDateTime.now()
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
return ResponseEntity.ok().body(addrService.addrMassInsertByTempAjax_advc(addrListVO, userId));
|
||||
return ResponseEntity.ok().body(addrService.addrMassInsertByTempAjax_advc(addrListVO, userId));
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
// TODO: handle exception
|
||||
return ResponseEntity.ok().body(new StatusResponse(
|
||||
HttpStatus.BAD_REQUEST
|
||||
, "오류가 발생하였습니다."
|
||||
, ""
|
||||
));
|
||||
}
|
||||
// return ResponseEntity.ok().body(addrService.addrMassInsertByTempAjax_advc(addrListVO, userId));
|
||||
}
|
||||
|
||||
//
|
||||
|
||||
Loading…
Reference in New Issue
Block a user