친구톡 환불로직 수정
This commit is contained in:
parent
1f0c38b791
commit
ffd779dd66
@ -71,6 +71,7 @@ public class KakaoSendAdvcVO implements Serializable {
|
||||
private String bizKakaoResendType; // 카카오 알림톡 단가
|
||||
private String filePath1; // 대체문자 이미지
|
||||
private String fileCnt; // 파일 카운트
|
||||
private String bizKakaoImageType; // 파일 카운트
|
||||
|
||||
|
||||
|
||||
@ -113,6 +114,7 @@ public class KakaoSendAdvcVO implements Serializable {
|
||||
"\n , bizKakaoResendOrgnlTxt=[" + bizKakaoResendOrgnlTxt + "]" +
|
||||
"\n , bizKakaoResendType=[" + bizKakaoResendType + "]" +
|
||||
"\n , filePath1=[" + filePath1 + "]" +
|
||||
"\n , bizKakaoImageType=[" + bizKakaoImageType + "]" +
|
||||
"\n ]";
|
||||
}
|
||||
|
||||
|
||||
@ -698,7 +698,7 @@ public class KakaoSendUtil {
|
||||
}
|
||||
|
||||
|
||||
public Float getValidPrice(Float personalPrice, Float defaultPrice) {
|
||||
public static Float getValidPrice(Float personalPrice, Float defaultPrice) {
|
||||
return (personalPrice != null && personalPrice > 0) ? personalPrice : defaultPrice;
|
||||
}
|
||||
|
||||
@ -1691,6 +1691,7 @@ public class KakaoSendUtil {
|
||||
sendVO.setAtDelayYn(kakaoVO.getAtSmishingYn());
|
||||
sendVO.setBizKakaoResendOrgnlTxt(kakaoVO.getSubMsgTxt());
|
||||
sendVO.setBizKakaoResendType(sendVO.getSubMsgType());
|
||||
sendVO.setBizKakaoImageType(kakaoVO.getImageType());
|
||||
|
||||
kakaoAlimTalkDAO.insertKakaoGroupDataTb_advc(sendVO);
|
||||
|
||||
|
||||
@ -175,14 +175,9 @@ public class KakaoFriendsTalkServiceImpl extends EgovAbstractServiceImpl implem
|
||||
kakaoSendUtil.insertKakaoGroupDataTb_advc(instCnt, kakaoVO, sendVO);
|
||||
|
||||
|
||||
/** @biz_kakao_price에 insert (대체문자 환불관련 테이블)*/
|
||||
kakaoVO.setMsgGroupId(sendVO.getMsgGroupId());
|
||||
kakaoVO.setKakaoFtPrice(Float.parseFloat(sendVO.getEachPrice()));
|
||||
kakaoVO.setSmsPrice(Float.parseFloat(sendVO.getSmsPrice()));
|
||||
kakaoVO.setMmsPrice(Float.parseFloat(sendVO.getMmsPrice()));
|
||||
kakaoVO.setPicturePrice(Float.parseFloat(sendVO.getPicturePrice()));
|
||||
|
||||
kakaoAlimTalkDAO.insertKakaoSendPrice(kakaoVO);
|
||||
/** @biz_kakao_price에 insert (대체문자 환불관련 테이블)*/
|
||||
priceAndPoint.insertBizFtKakaoPrice(kakaoVO.getUserId(), sendVO.getMsgGroupId());
|
||||
|
||||
|
||||
priceAndPoint.insertCashAndPoint(kakaoVO.getUserId()
|
||||
|
||||
@ -303,6 +303,8 @@ public class MjonMsgVO extends ComDefaultVO{
|
||||
private String bizLogCallStatusTxt; //다우기술 biz_log 테이블의 발송결과 내용 텍스트.
|
||||
private String bizLogStatus; //다우기술 biz_log 테이블의 전송상태값
|
||||
|
||||
private String bizKakaoImageType; // 비즈 발송 img 값
|
||||
|
||||
private String accessKey; // 'API Key',
|
||||
|
||||
private int regCount;
|
||||
|
||||
@ -9,14 +9,21 @@ import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
import egovframework.rte.fdl.idgnr.EgovIdGnrService;
|
||||
import itn.let.kakao.kakaoComm.KakaoSendAdvcVO;
|
||||
import itn.let.kakao.kakaoComm.KakaoSendUtil;
|
||||
import itn.let.kakao.kakaoComm.KakaoVO;
|
||||
import itn.let.kakao.user.kakaoAt.service.impl.KakaoAlimTalkDAO;
|
||||
import itn.let.mjo.event.service.MjonEventService;
|
||||
import itn.let.mjo.event.service.MjonEventVO;
|
||||
import itn.let.mjo.event.service.impl.MjonEventDAO;
|
||||
import itn.let.mjo.msg.service.MjonMsgVO;
|
||||
import itn.let.mjo.msgdata.service.MjonMsgDataService;
|
||||
import itn.let.mjo.msgdata.service.impl.MjonMsgDataDAO;
|
||||
import itn.let.mjo.pay.service.MjonPayVO;
|
||||
import itn.let.mjo.pay.service.impl.MjonPayDAO;
|
||||
import itn.let.sym.site.service.JoinSettingVO;
|
||||
import itn.let.uss.umt.service.MberManageVO;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
|
||||
/**
|
||||
*
|
||||
@ -32,6 +39,7 @@ import itn.let.uss.umt.service.MberManageVO;
|
||||
*
|
||||
*
|
||||
*/
|
||||
@Slf4j
|
||||
@Component
|
||||
public class PriceAndPoint {
|
||||
|
||||
@ -47,6 +55,11 @@ public class PriceAndPoint {
|
||||
@Resource(name = "egovMjonCashIdGnrService")
|
||||
private EgovIdGnrService idgenMjonCashId;
|
||||
|
||||
@Resource(name="kakaoAlimTalkDAO")
|
||||
private KakaoAlimTalkDAO kakaoAlimTalkDAO;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* @methodName : getBefCash
|
||||
* @author : 이호영
|
||||
@ -128,5 +141,30 @@ public class PriceAndPoint {
|
||||
|
||||
}
|
||||
|
||||
public void insertBizFtKakaoPrice(String userId, String msgGroupId) throws Exception {
|
||||
KakaoVO kakaoVO = new KakaoVO();
|
||||
|
||||
// 사용자 개인 단가 정보 불러오기
|
||||
MberManageVO mberManageVO = mjonMsgDataDAO.selectMberManageInfo(userId);
|
||||
// 시스템 기본 단가 정보 불러오기
|
||||
JoinSettingVO sysJoinSetVO = mjonMsgDataDAO.selectJoinSettingInfo();
|
||||
KakaoSendUtil.getValidPrice(mberManageVO.getShortPrice(), sysJoinSetVO.getShortPrice());
|
||||
// TODO Auto-generated method stub
|
||||
kakaoVO.setMsgGroupId(msgGroupId);
|
||||
|
||||
kakaoVO.setSmsPrice(KakaoSendUtil.getValidPrice(mberManageVO.getShortPrice(), sysJoinSetVO.getShortPrice()));
|
||||
kakaoVO.setMmsPrice(KakaoSendUtil.getValidPrice(mberManageVO.getLongPrice(), sysJoinSetVO.getLongPrice()));
|
||||
kakaoVO.setPicturePrice(KakaoSendUtil.getValidPrice(mberManageVO.getPicturePrice(), sysJoinSetVO.getPicturePrice()));
|
||||
|
||||
kakaoVO.setKakaoFtPrice(KakaoSendUtil.getValidPrice(mberManageVO.getKakaoFtPrice(), sysJoinSetVO.getKakaoFtPrice()));
|
||||
kakaoVO.setKakaoFtImgPrice(KakaoSendUtil.getValidPrice(mberManageVO.getKakaoFtImgPrice(), sysJoinSetVO.getKakaoFtImgPrice()));
|
||||
kakaoVO.setKakaoFtWideImgPrice(KakaoSendUtil.getValidPrice(mberManageVO.getKakaoFtWideImgPrice(), sysJoinSetVO.getKakaoFtWideImgPrice()));
|
||||
|
||||
|
||||
|
||||
kakaoAlimTalkDAO.insertKakaoSendPrice(kakaoVO);
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@ -151,7 +151,8 @@
|
||||
|
||||
AT_DELAY_YN,
|
||||
BIZ_KAKAO_RESEND_ORGNL_TXT,
|
||||
BIZ_KAKAO_RESEND_TYPE
|
||||
BIZ_KAKAO_RESEND_TYPE,
|
||||
BIZ_KAKAO_IMAGE_TYPE
|
||||
)VALUES
|
||||
(
|
||||
#msgGroupId#,
|
||||
@ -174,7 +175,8 @@
|
||||
|
||||
#atDelayYn#,
|
||||
#bizKakaoResendOrgnlTxt#,
|
||||
#bizKakaoResendType#
|
||||
#bizKakaoResendType#,
|
||||
#bizKakaoImageType#
|
||||
)
|
||||
</insert>
|
||||
|
||||
@ -230,6 +232,7 @@
|
||||
MMD.USER_ID AS userId
|
||||
, MMD.MSG_GROUP_ID AS msgGroupId
|
||||
, MMD.MSG_SEQ AS msgSeq
|
||||
, MMGD.BIZ_KAKAO_IMAGE_TYPE AS bizKakaoImageType
|
||||
, MMD.USERDATA AS userData
|
||||
, MMD.REFUND_YN AS refundYn
|
||||
, MMD.RSLT_CODE AS rsltCode
|
||||
@ -241,11 +244,12 @@
|
||||
, MMD.BIZ_KAKAO_RESEND_TYPE AS subMsgType
|
||||
, MMD.FILE_CNT AS fileCnt
|
||||
, MMD.BIZ_KAKAO_RESEND_TYPE AS bizKakaoResendType
|
||||
|
||||
FROM
|
||||
MJ_MSG_DATA MMD
|
||||
INNER JOIN LETTNGNRLMBER MB
|
||||
ON MMD.USER_ID = MB.MBER_ID
|
||||
INNER JOIN mj_msg_group_data MMGD
|
||||
on MMD.MSG_GROUP_ID = MMGD.MSG_GROUP_ID
|
||||
WHERE 1=1
|
||||
AND MMD.CUR_STATE = '3'
|
||||
AND MMD.REFUND_YN = 'N'
|
||||
@ -281,7 +285,7 @@
|
||||
|
||||
<!-- 카카오 친구톡 전송 환불 프로시저 실행 (카카오 전송 성공 관련 - 대체문자 선택시 차액 환불 처리) -->
|
||||
<procedure id="kakaoAlimTalkDAO.updateKakaoFtSend" parameterClass="kakaoVO">
|
||||
{call kakaoFt_Send(#userId#, #msgGroupId#, #userData#, #fileCnt#, #bizKakaoResendType#)}
|
||||
{call kakaoFt_Send(#userId#, #msgGroupId#, #userData#, #fileCnt#, #bizKakaoResendType#, #bizKakaoImageType#)}
|
||||
</procedure>
|
||||
|
||||
<!-- 카카오 친구톡 전송 환불 프로시저 실행 (카카오 전송 실패시 대체문자 관련 - 대체문자 발송 완료 된 경우) -->
|
||||
|
||||
Loading…
Reference in New Issue
Block a user