이호영 이호영 2025-08-07
Merge branch '5102_친구톡_발송속도_개선' of http://hylee@vcs.iten.co.kr:9999/hylee/mjon_git into 5102_친구톡_발송속도_개선
@05f13875bdd5699d023fec0ad5014e9d9cfe6ed5
src/main/resources/egovframework/sqlmap/let/mjo/kakao/KakaoSent_SQL_Mysql.xml
--- src/main/resources/egovframework/sqlmap/let/mjo/kakao/KakaoSent_SQL_Mysql.xml
+++ src/main/resources/egovframework/sqlmap/let/mjo/kakao/KakaoSent_SQL_Mysql.xml
@@ -1820,8 +1820,19 @@
 		    , a.failCount
 		    , a.kakaoResendSuccCount
 		    , a.kakaoResendFailCount
-		    , a.successCount * bkp.BIZ_KAKAO_AT_PRICE                                        AS successPrice
-		    , (a.smsCnt      * bkp.BIZ_SMS_PRICE) + (a.mmsCnt * bkp.BIZ_MMS_PRICE)			 AS kakaoResendSuccPrice
+		    <!-- , a.successCount * bkp.BIZ_KAKAO_AT_PRICE                                        AS successPrice -->
+		    ,case
+	           when a.msgType = '8' then a.successCount * bkp.BIZ_KAKAO_AT_PRICE
+	           when a.msgType = '9' and a.bizKakaoImageType = 'I' then a.successCount * bkp.BIZ_KAKAO_FT_IMG_PRICE
+	           when a.msgType = '9' and a.bizKakaoImageType = 'W' then a.successCount * bkp.BIZ_KAKAO_FT_WIDE_IMG_PRICE
+	           when a.msgType = '9' and a.bizKakaoImageType != 'I' and a.bizKakaoImageType != 'W' then a.successCount * bkp.BIZ_KAKAO_FT_PRICE
+	       end successPrice
+		    <!-- , (a.smsCnt      * bkp.BIZ_SMS_PRICE) + (a.mmsCnt * bkp.BIZ_MMS_PRICE)			 AS kakaoResendSuccPrice -->
+		    ,case
+	           when a.msgType = '8' then (a.smsCnt * bkp.BIZ_SMS_PRICE) + (a.mmsCnt * bkp.BIZ_MMS_PRICE)
+	           when a.msgType = '9' and (a.bizKakaoImageType = 'I' or a.bizKakaoImageType = 'W') then a.mmsCnt * bkp.BIZ_PICTURE_PRICE
+	           when a.msgType = '9' and a.bizKakaoImageType != 'I' and a.bizKakaoImageType != 'W' then (a.smsCnt * bkp.BIZ_SMS_PRICE) + (a.mmsCnt * bkp.BIZ_MMS_PRICE)
+           end kakaoResendSuccPrice
 		    , a.divideYn
 		    , a.bizKakaoResendYn
 		    , MKPI.YELLOW_ID AS yellowId
@@ -1947,6 +1958,7 @@
 					, MD.BIZ_KAKAO_RESEND_YN as bizKakaoResendYn
 					, MD.MSG_NOTICETALK_SENDER_KEY
 					, MD.MSG_NOTICETALK_TMP_KEY
+					, MGD.BIZ_KAKAO_IMAGE_TYPE                                        as bizKakaoImageType
 				FROM     MJ_MSG_DATA MD
 		        inner join MJ_MSG_GROUP_DATA MGD on
 					MGD.MSG_GROUP_ID = MD.MSG_GROUP_ID
Add a comment
List