|
|
@ -9,9 +9,12 @@ import kr.xit.biz.ens.model.kt.KtCommonDTO.KtCommonResponse;
|
|
|
|
import kr.xit.biz.ens.model.kt.KtCommonDTO.KtMnsRequest;
|
|
|
|
import kr.xit.biz.ens.model.kt.KtCommonDTO.KtMnsRequest;
|
|
|
|
import kr.xit.biz.ens.model.kt.KtMmsSendDTO.KtMainSendReqData;
|
|
|
|
import kr.xit.biz.ens.model.kt.KtMmsSendDTO.KtMainSendReqData;
|
|
|
|
import kr.xit.biz.ens.model.kt.KtMmsSendDTO.KtMainSendRequest;
|
|
|
|
import kr.xit.biz.ens.model.kt.KtMmsSendDTO.KtMainSendRequest;
|
|
|
|
|
|
|
|
import kr.xit.biz.ens.model.kt.KtMmsSendDTO.KtMsgRsltReqData;
|
|
|
|
|
|
|
|
import kr.xit.biz.ens.model.kt.KtMmsSendDTO.KtMsgRsltRequest;
|
|
|
|
import kr.xit.biz.ens.model.kt.KtTokenDTO.KtTokenResponse;
|
|
|
|
import kr.xit.biz.ens.model.kt.KtTokenDTO.KtTokenResponse;
|
|
|
|
import kr.xit.biz.kt.mapper.IBizKtMmsMapper;
|
|
|
|
import kr.xit.biz.kt.mapper.IBizKtMmsMapper;
|
|
|
|
import kr.xit.core.exception.BizRuntimeException;
|
|
|
|
import kr.xit.core.exception.BizRuntimeException;
|
|
|
|
|
|
|
|
import kr.xit.core.support.utils.DateUtils;
|
|
|
|
import kr.xit.ens.kt.service.IKtMmsService;
|
|
|
|
import kr.xit.ens.kt.service.IKtMmsService;
|
|
|
|
import lombok.RequiredArgsConstructor;
|
|
|
|
import lombok.RequiredArgsConstructor;
|
|
|
|
import org.apache.commons.collections4.ListUtils;
|
|
|
|
import org.apache.commons.collections4.ListUtils;
|
|
|
@ -105,7 +108,8 @@ public class BizKtMmsService extends EgovAbstractServiceImpl implements IBizKtMm
|
|
|
|
KtCommonResponse ktTokenResponse = null;
|
|
|
|
KtCommonResponse ktTokenResponse = null;
|
|
|
|
|
|
|
|
|
|
|
|
for(List<KtMainSendReqData> reqs : parts) {
|
|
|
|
for(List<KtMainSendReqData> reqs : parts) {
|
|
|
|
KtMainSendRequest ktReqDTO = KtMainSendRequest.builder()
|
|
|
|
ktTokenResponse = ktMmsService.mainSend(
|
|
|
|
|
|
|
|
KtMainSendRequest.builder()
|
|
|
|
.signguCode(reqDTO.getSignguCode())
|
|
|
|
.signguCode(reqDTO.getSignguCode())
|
|
|
|
.ffnlgCode(reqDTO.getFfnlgCode())
|
|
|
|
.ffnlgCode(reqDTO.getFfnlgCode())
|
|
|
|
.profile(profile)
|
|
|
|
.profile(profile)
|
|
|
@ -122,14 +126,48 @@ public class BizKtMmsService extends EgovAbstractServiceImpl implements IBizKtMm
|
|
|
|
.fileFmat("db")
|
|
|
|
.fileFmat("db")
|
|
|
|
.testSndnYn("N")
|
|
|
|
.testSndnYn("N")
|
|
|
|
.reqs(reqs)
|
|
|
|
.reqs(reqs)
|
|
|
|
|
|
|
|
.build()
|
|
|
|
|
|
|
|
);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
return ktTokenResponse;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Override
|
|
|
|
|
|
|
|
public KtCommonResponse messageResult(final KtMnsRequest reqDTO) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
List<KtMsgRsltReqData> rsltReqs = new ArrayList<>();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
KtMsgRsltReqData reqData = KtMsgRsltReqData.builder()
|
|
|
|
|
|
|
|
.srcKey("db")
|
|
|
|
|
|
|
|
.mmsSndgRsltSqno(1) // ++
|
|
|
|
|
|
|
|
.prcsDt("YYYYMMDD")
|
|
|
|
|
|
|
|
.mmsBsnsDvcd("12345")
|
|
|
|
|
|
|
|
//.mblBzowrDvcd("01")
|
|
|
|
|
|
|
|
.mmsSndgRsltDvcd("40")
|
|
|
|
|
|
|
|
.mmsRdgTmst(DateUtils.getTodayAndNowTime("yyyyMMddHHmmss"))
|
|
|
|
|
|
|
|
//.msgType("2")
|
|
|
|
.build();
|
|
|
|
.build();
|
|
|
|
|
|
|
|
rsltReqs.add(reqData);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
List<List<KtMsgRsltReqData>> parts = ListUtils.partition(rsltReqs, MAX_KT_SEND_CNT);
|
|
|
|
|
|
|
|
KtCommonResponse ktTokenResponse = null;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
for(List<KtMsgRsltReqData> reqs : parts) {
|
|
|
|
|
|
|
|
ktTokenResponse = ktMmsService.messageResult(
|
|
|
|
|
|
|
|
KtMsgRsltRequest.builder()
|
|
|
|
|
|
|
|
.signguCode(reqDTO.getSignguCode())
|
|
|
|
|
|
|
|
.ffnlgCode(reqDTO.getFfnlgCode())
|
|
|
|
|
|
|
|
.profile(profile)
|
|
|
|
|
|
|
|
.reqs(reqs)
|
|
|
|
|
|
|
|
.build()
|
|
|
|
|
|
|
|
);
|
|
|
|
|
|
|
|
|
|
|
|
ktTokenResponse = ktMmsService.mainSend(ktReqDTO);
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return ktTokenResponse;
|
|
|
|
return ktTokenResponse;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// /**
|
|
|
|
// /**
|
|
|
|
// * 사전 문자 수신 등록 요청(BC-AG-SN-001)
|
|
|
|
// * 사전 문자 수신 등록 요청(BC-AG-SN-001)
|
|
|
|
// * @param reqDTO
|
|
|
|
// * @param reqDTO
|
|
|
|