Merge branch 'master' of

http://yongjoon.cho@vcs.iten.co.kr:9999/hylee/mjon_api
This commit is contained in:
myname 2023-05-31 18:14:40 +09:00
parent 86b15ca473
commit 044435c4ae
4 changed files with 32 additions and 18 deletions

View File

@ -43,6 +43,12 @@ public enum StatMsg {
, STAT_1090("1090","요청 발송일시에 발송 불가") // 아직 사용 안함
, STAT_1099("1099","기타 시스템 오류")
//전체발송======================================================================
, STAT_3099("3099","기타 시스템 오류")
//상세발송======================================================================
, STAT_4099("4099","기타 시스템 오류")
//======================================================================
, msgType4("단문","SMS")
, msgType6("장문","LMS")

View File

@ -1,5 +1,6 @@
package com.itn.mjonApi.mjon.api.inqry.service;
import com.itn.mjonApi.cmn.msg.RestResponse;
import com.itn.mjonApi.mjon.api.inqry.service.mapper.domain.HstryDetailVO;
import com.itn.mjonApi.mjon.api.inqry.service.mapper.domain.HstryResponseVO;
import com.itn.mjonApi.mjon.api.inqry.service.mapper.domain.HstryVO;
@ -9,7 +10,7 @@ public interface HstryService {
//HstryResponseVO hstryListOld(MsgRequestVO msgRequestVO) throws Exception;
HstryResponseVO hstryList(HstryVO hstryVO) throws Exception;
RestResponse hstryList(HstryVO hstryVO) throws Exception;
HstryResponseVO hstryDetailList(HstryDetailVO HstryDetailVO) throws Exception;
RestResponse hstryDetailList(HstryDetailVO HstryDetailVO) throws Exception;
}

View File

@ -7,6 +7,8 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.itn.mjonApi.cmn.apiServer.ApiService;
import com.itn.mjonApi.cmn.msg.RestResponse;
import com.itn.mjonApi.cmn.msg.SendSuccessRestResponse;
import com.itn.mjonApi.mjon.api.access.mapper.domain.AccessKeyVO;
import com.itn.mjonApi.mjon.api.inqry.mapper.HstryMapper;
import com.itn.mjonApi.mjon.api.inqry.service.HstryService;
@ -37,8 +39,9 @@ public class HstryServiceImpl implements HstryService {
private static final String replaseStrList = "[*이름*],[*1*],[*2*],[*3*],[*4*]";
@Override
public HstryResponseVO hstryList(HstryVO hstryVO) throws Exception {
public RestResponse hstryList(HstryVO hstryVO) throws Exception {
//전체 발송 이력
log.info(" :: hstryList ::");
@ -84,15 +87,15 @@ public class HstryServiceImpl implements HstryService {
} catch (Exception e) {
log.info("selectPrice Error [{}]", e.getMessage());
return new RestResponse("STAT_3090");
}
return hstryResponseVO;
return new RestResponse(hstryResponseVO);
}
@Override
public HstryResponseVO hstryDetailList(HstryDetailVO hstryDetailVO) throws Exception {
public RestResponse hstryDetailList(HstryDetailVO hstryDetailVO) throws Exception {
//전체 발송 이력
log.info(" :: hstryList ::");
@ -113,9 +116,10 @@ public class HstryServiceImpl implements HstryService {
} catch (Exception e) {
log.info("selectPrice Error [{}]", e.getMessage());
return new RestResponse("STAT_4090");
}
return hstryResponseVO;
return new RestResponse(hstryResponseVO);
}

View File

@ -7,6 +7,7 @@ import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.client.RestTemplate;
import com.itn.mjonApi.cmn.msg.RestResponse;
import com.itn.mjonApi.mjon.api.inqry.service.HstryService;
import com.itn.mjonApi.mjon.api.inqry.service.mapper.domain.HstryDetailVO;
import com.itn.mjonApi.mjon.api.inqry.service.mapper.domain.HstryResponseVO;
@ -51,9 +52,11 @@ public class HstryRestController {
@CrossOrigin("*") // 모든 요청에 접근 허용
@PostMapping("/api/inqry/hstry")
@ApiOperation(value= "전송 내역 조회", notes = "전체 전송 내역 조회")
public ResponseEntity<HstryResponseVO> apiInqryHstry(HstryVO hstryVO) throws Exception {
public ResponseEntity<RestResponse> apiInqryHstry(HstryVO hstryVO) throws Exception {
return ResponseEntity.ok(hstryService.hstryList(hstryVO));
return ResponseEntity.ok().body(hstryService.hstryList(hstryVO));
//return ResponseEntity.ok(hstryService.hstryList(hstryVO));
//return sendService.sendMsgData(msgRequestVO);
@ -68,9 +71,9 @@ public class HstryRestController {
@CrossOrigin("*") // 모든 요청에 접근 허용
@PostMapping("/api/inqry/hstryDetail")
@ApiOperation(value= "전송 내역 조회(상세)", notes = "상세 전송 내역 조회")
public ResponseEntity<HstryResponseVO> apiInqryHstryDetail(HstryDetailVO hstryDetailVO) throws Exception {
public ResponseEntity<RestResponse> apiInqryHstryDetail(HstryDetailVO hstryDetailVO) throws Exception {
return ResponseEntity.ok(hstryService.hstryDetailList(hstryDetailVO));
return ResponseEntity.ok().body(hstryService.hstryDetailList(hstryDetailVO));
//return sendService.sendMsgData(msgRequestVO);