B선 전송사 이용고객 => 이벤트대상 제외처리
@e2a7a09ff59c00d8c517ac78cb0d866f235494ed
--- src/main/java/itn/let/mjo/event/web/MjonEventController.java
+++ src/main/java/itn/let/mjo/event/web/MjonEventController.java
... | ... | @@ -124,35 +124,46 @@ |
| 124 | 124 |
return modelAndView; |
| 125 | 125 |
|
| 126 | 126 |
} |
| 127 |
+ |
|
| 128 |
+ // Step 0. B선 전송사 이용고객 => 이벤트대상 제외처리 |
|
| 129 |
+ MberManageVO mberManageVO = new MberManageVO(); |
|
| 130 |
+ mberManageVO.setMberId(loginVO.getId()); |
|
| 131 |
+ String blineCode = mberManageService.selectBlineCodeByMberId(mberManageVO); |
|
| 132 |
+ if (blineCode != null && blineCode.equals("N")) {
|
|
| 127 | 133 |
|
| 128 |
- //이벤트 회원 정보 조회 |
|
| 129 |
- MjonEventVO eventMberInfo = selectEventMsgMberDefaultInfo(mjonEventVO, resultEvent.getNttId(), bbsId, loginVO.getId(), loginVO.getName()); |
|
| 130 |
- |
|
| 131 |
- int resultCnt = 0; |
|
| 132 |
- |
|
| 133 |
- if(eventMberInfo == null) {//등록된 회원정보가 없으면 정보 입력
|
|
| 134 |
- mjonEventVO.setEventStatus("N");
|
|
| 135 |
- resultCnt = mjonEventService.insertEventMsgMberDefaultInfo(mjonEventVO); |
|
| 136 |
- }else {//등록된 회원정보가 있으면 화면 이동 및 메세지 처리
|
|
| 134 |
+ //이벤트 회원 정보 조회 |
|
| 135 |
+ MjonEventVO eventMberInfo = selectEventMsgMberDefaultInfo(mjonEventVO, resultEvent.getNttId(), bbsId, loginVO.getId(), loginVO.getName()); |
|
| 137 | 136 |
|
| 138 |
- String status = eventMberInfo.getEventStatus(); |
|
| 137 |
+ int resultCnt = 0; |
|
| 139 | 138 |
|
| 140 |
- if(status.equals("Y")) {//이벤트가 진행중인 경우
|
|
| 139 |
+ if(eventMberInfo == null) {//등록된 회원정보가 없으면 정보 입력
|
|
| 140 |
+ mjonEventVO.setEventStatus("N");
|
|
| 141 |
+ resultCnt = mjonEventService.insertEventMsgMberDefaultInfo(mjonEventVO); |
|
| 142 |
+ }else {//등록된 회원정보가 있으면 화면 이동 및 메세지 처리
|
|
| 141 | 143 |
|
| 142 |
- modelAndView.addObject("resultSts", "eventJoined");
|
|
| 144 |
+ String status = eventMberInfo.getEventStatus(); |
|
| 143 | 145 |
|
| 144 |
- }else if(status.equals("E")) {//이벤트가 종료된 경우
|
|
| 146 |
+ if(status.equals("Y")) {//이벤트가 진행중인 경우
|
|
| 147 |
+ |
|
| 148 |
+ modelAndView.addObject("resultSts", "eventJoined");
|
|
| 149 |
+ |
|
| 150 |
+ }else if(status.equals("E")) {//이벤트가 종료된 경우
|
|
| 151 |
+ |
|
| 152 |
+ modelAndView.addObject("resultSts", "eventEnded");
|
|
| 153 |
+ |
|
| 154 |
+ }else {//이벤트 미진행인 경우 성공으로 결제페이지로 이동되도록 한다.
|
|
| 155 |
+ |
|
| 156 |
+ modelAndView.addObject("resultSts", "success");
|
|
| 157 |
+ |
|
| 158 |
+ } |
|
| 145 | 159 |
|
| 146 |
- modelAndView.addObject("resultSts", "eventEnded");
|
|
| 147 |
- |
|
| 148 |
- }else {//이벤트 미진행인 경우 성공으로 결제페이지로 이동되도록 한다.
|
|
| 149 |
- |
|
| 150 |
- modelAndView.addObject("resultSts", "success");
|
|
| 151 |
- |
|
| 160 |
+ return modelAndView; |
|
| 152 | 161 |
} |
| 162 |
+ } |
|
| 163 |
+ else {
|
|
| 164 |
+ modelAndView.addObject("resultSts", "eventBline");
|
|
| 153 | 165 |
|
| 154 |
- return modelAndView; |
|
| 155 |
- |
|
| 166 |
+ return modelAndView; |
|
| 156 | 167 |
} |
| 157 | 168 |
|
| 158 | 169 |
modelAndView.addObject("resultSts", "success");
|
--- src/main/java/itn/let/uat/uia/service/impl/EgovMberManageServiceImpl.java
+++ src/main/java/itn/let/uat/uia/service/impl/EgovMberManageServiceImpl.java
... | ... | @@ -350,6 +350,11 @@ |
| 350 | 350 |
return mberManageDAO.selectMberNmByMberId(mberManageVO); |
| 351 | 351 |
} |
| 352 | 352 |
|
| 353 |
+ @Override |
|
| 354 |
+ public String selectBlineCodeByMberId(MberManageVO mberManageVO) throws Exception {
|
|
| 355 |
+ return mberManageDAO.selectBlineCodeByMberId(mberManageVO); |
|
| 356 |
+ } |
|
| 357 |
+ |
|
| 353 | 358 |
//개인 문자전송 금액 수정하기 |
| 354 | 359 |
public int updateUserPrice(MberManageVO mberManageVO) throws Exception{
|
| 355 | 360 |
return mberManageDAO.updateUserPrice(mberManageVO); |
--- src/main/java/itn/let/uat/uia/service/impl/MberManageDAO.java
+++ src/main/java/itn/let/uat/uia/service/impl/MberManageDAO.java
... | ... | @@ -186,6 +186,10 @@ |
| 186 | 186 |
return (String) select("mberManageDAO.selectMberNmByMberId",mberManageVO);
|
| 187 | 187 |
} |
| 188 | 188 |
|
| 189 |
+ public String selectBlineCodeByMberId(MberManageVO mberManageVO) {
|
|
| 190 |
+ return (String) select("mberManageDAO.selectBlineCodeByMberId",mberManageVO);
|
|
| 191 |
+ } |
|
| 192 |
+ |
|
| 189 | 193 |
//개인 문자전송 금액 수정하기 |
| 190 | 194 |
public int updateUserPrice(MberManageVO mberManageVO) throws Exception{
|
| 191 | 195 |
return update("mberManageDAO.updateUserPrice", mberManageVO);
|
--- src/main/java/itn/let/uat/uia/web/EgovLoginController.java
+++ src/main/java/itn/let/uat/uia/web/EgovLoginController.java
... | ... | @@ -1726,7 +1726,7 @@ |
| 1726 | 1726 |
public boolean goEventPay(LoginVO loginVO) throws Exception {
|
| 1727 | 1727 |
boolean goEventPay = false; |
| 1728 | 1728 |
MjonEventVO mjonEventVO = new MjonEventVO(); |
| 1729 |
- |
|
| 1729 |
+ |
|
| 1730 | 1730 |
// 이벤트 컨텐츠 정보 불러오기 |
| 1731 | 1731 |
String bbsId = "BBSMSTR_000000000731"; //이벤트 게시판 번호 |
| 1732 | 1732 |
String nttSj = "[첫결제 이벤트] 첫 결제 시, 누구나 조건 없이 인생 최저가!"; |
... | ... | @@ -1742,29 +1742,34 @@ |
| 1742 | 1742 |
if (mberNm != null) {
|
| 1743 | 1743 |
loginVO.setName(mberNm); |
| 1744 | 1744 |
} |
| 1745 |
- |
|
| 1746 |
- // Step 1. 결제여부 체크(미결제 일때 이벤트 대상) |
|
| 1747 |
- int payCnt = mjonPayService.selectMemerPayCount(loginVO.getId()); |
|
| 1748 |
- if (payCnt == 0) {
|
|
| 1749 |
- // Step 2. 이벤트 회원 정보 조회 |
|
| 1750 |
- MjonEventVO eventMberInfo = selectEventMsgMberDefaultInfo(mjonEventVO, resultEvent.getNttId(), bbsId, loginVO.getId(), loginVO.getName()); |
|
| 1751 |
- if(eventMberInfo == null) {//등록된 회원정보가 없으면 정보 입력
|
|
| 1752 |
- mjonEventVO.setEventStatus("N");
|
|
| 1753 |
- int resultCnt = mjonEventService.insertEventMsgMberDefaultInfo(mjonEventVO); |
|
| 1754 |
- if (resultCnt > 0) {
|
|
| 1755 |
- goEventPay = true; |
|
| 1756 |
- } |
|
| 1757 |
- }else {
|
|
| 1758 |
- //등록된 회원정보가 있으면 화면 이동 및 메세지 처리 |
|
| 1759 |
- String status = eventMberInfo.getEventStatus(); |
|
| 1760 |
- if(status.equals("Y")) {
|
|
| 1761 |
- //이벤트가 진행중인 경우 |
|
| 1762 |
- } |
|
| 1763 |
- else if(status.equals("E")) {
|
|
| 1764 |
- //이벤트가 종료된 경우 |
|
| 1745 |
+ |
|
| 1746 |
+ // Step 0. B선 전송사 이용고객 => 이벤트대상 제외처리 |
|
| 1747 |
+ mberManageVO.setMberId(loginVO.getId()); |
|
| 1748 |
+ String blineCode = mberManageService.selectBlineCodeByMberId(mberManageVO); |
|
| 1749 |
+ if (blineCode != null && blineCode.equals("N")) {
|
|
| 1750 |
+ // Step 1. 결제여부 체크(미결제 일때 이벤트 대상) |
|
| 1751 |
+ int payCnt = mjonPayService.selectMemerPayCount(loginVO.getId()); |
|
| 1752 |
+ if (payCnt == 0) {
|
|
| 1753 |
+ // Step 2. 이벤트 회원 정보 조회 |
|
| 1754 |
+ MjonEventVO eventMberInfo = selectEventMsgMberDefaultInfo(mjonEventVO, resultEvent.getNttId(), bbsId, loginVO.getId(), loginVO.getName()); |
|
| 1755 |
+ if(eventMberInfo == null) {//등록된 회원정보가 없으면 정보 입력
|
|
| 1756 |
+ mjonEventVO.setEventStatus("N");
|
|
| 1757 |
+ int resultCnt = mjonEventService.insertEventMsgMberDefaultInfo(mjonEventVO); |
|
| 1758 |
+ if (resultCnt > 0) {
|
|
| 1759 |
+ goEventPay = true; |
|
| 1760 |
+ } |
|
| 1765 | 1761 |
}else {
|
| 1766 |
- //이벤트 미진행인 경우 성공으로 결제페이지로 이동되도록 한다. |
|
| 1767 |
- goEventPay = true; |
|
| 1762 |
+ //등록된 회원정보가 있으면 화면 이동 및 메세지 처리 |
|
| 1763 |
+ String status = eventMberInfo.getEventStatus(); |
|
| 1764 |
+ if(status.equals("Y")) {
|
|
| 1765 |
+ //이벤트가 진행중인 경우 |
|
| 1766 |
+ } |
|
| 1767 |
+ else if(status.equals("E")) {
|
|
| 1768 |
+ //이벤트가 종료된 경우 |
|
| 1769 |
+ }else {
|
|
| 1770 |
+ //이벤트 미진행인 경우 성공으로 결제페이지로 이동되도록 한다. |
|
| 1771 |
+ goEventPay = true; |
|
| 1772 |
+ } |
|
| 1768 | 1773 |
} |
| 1769 | 1774 |
} |
| 1770 | 1775 |
} |
--- src/main/java/itn/let/uss/umt/service/EgovMberManageService.java
+++ src/main/java/itn/let/uss/umt/service/EgovMberManageService.java
... | ... | @@ -184,6 +184,8 @@ |
| 184 | 184 |
|
| 185 | 185 |
public String selectMberNmByMberId(MberManageVO mberManageVO) throws Exception; |
| 186 | 186 |
|
| 187 |
+ public String selectBlineCodeByMberId(MberManageVO mberManageVO) throws Exception; |
|
| 188 |
+ |
|
| 187 | 189 |
//개인 문자전송 금액 수정하기 |
| 188 | 190 |
public int updateUserPrice(MberManageVO mberManageVO) throws Exception; |
| 189 | 191 |
//개인 팩스전송 금액 수정하기 |
--- src/main/java/itn/web/MainController.java
+++ src/main/java/itn/web/MainController.java
... | ... | @@ -125,7 +125,9 @@ |
| 125 | 125 |
import itn.let.sym.site.service.EgovSiteManagerService; |
| 126 | 126 |
import itn.let.sym.site.service.MetaTagVO; |
| 127 | 127 |
import itn.let.sym.site.service.SiteManagerVO; |
| 128 |
+import itn.let.uss.umt.service.EgovMberManageService; |
|
| 128 | 129 |
import itn.let.uss.umt.service.EgovUserManageService; |
| 130 |
+import itn.let.uss.umt.service.MberManageVO; |
|
| 129 | 131 |
import itn.let.uss.umt.service.UserManageVO; |
| 130 | 132 |
import itn.let.utl.sim.service.EgovClntInfo; |
| 131 | 133 |
|
... | ... | @@ -249,6 +251,10 @@ |
| 249 | 251 |
|
| 250 | 252 |
@Resource(name = "userManageService") |
| 251 | 253 |
private EgovUserManageService userManageService; |
| 254 |
+ |
|
| 255 |
+ /** mberManageService */ |
|
| 256 |
+ @Resource(name = "mberManageService") |
|
| 257 |
+ private EgovMberManageService mberManageService; |
|
| 252 | 258 |
|
| 253 | 259 |
@Value("#{globalSettings['Globals.email.host']}")
|
| 254 | 260 |
private String Globals_email_host; |
... | ... | @@ -652,6 +658,14 @@ |
| 652 | 658 |
|
| 653 | 659 |
model.addAttribute("resultEvent", resultEvent);
|
| 654 | 660 |
|
| 661 |
+ String blineCode = "N"; |
|
| 662 |
+ if(StringUtil.isNotEmpty(userId)) {
|
|
| 663 |
+ // B선 전송사 사용여부 |
|
| 664 |
+ MberManageVO mberManageVO = new MberManageVO(); |
|
| 665 |
+ mberManageVO.setMberId(userId); |
|
| 666 |
+ blineCode = mberManageService.selectBlineCodeByMberId(mberManageVO); |
|
| 667 |
+ } |
|
| 668 |
+ model.addAttribute("blineCode", blineCode);
|
|
| 655 | 669 |
} |
| 656 | 670 |
|
| 657 | 671 |
return "web/main/mainPage"; |
--- src/main/resources/egovframework/sqlmap/let/uss/umt/EgovMberManage_SQL_Mysql.xml
+++ src/main/resources/egovframework/sqlmap/let/uss/umt/EgovMberManage_SQL_Mysql.xml
... | ... | @@ -1192,6 +1192,13 @@ |
| 1192 | 1192 |
WHERE A.MBER_ID= #mberId# |
| 1193 | 1193 |
</select> |
| 1194 | 1194 |
|
| 1195 |
+ <select id="mberManageDAO.selectBlineCodeByMberId" parameterClass="mberVO" resultClass="String"> |
|
| 1196 |
+ SELECT |
|
| 1197 |
+ IFNULL(A.BLINE_CODE, 'N') AS blineCode |
|
| 1198 |
+ FROM LETTNGNRLMBER A |
|
| 1199 |
+ WHERE A.MBER_ID= #mberId# |
|
| 1200 |
+ </select> |
|
| 1201 |
+ |
|
| 1195 | 1202 |
<update id="mberManageDAO.updateUserPrice" parameterClass="mberVO"> |
| 1196 | 1203 |
|
| 1197 | 1204 |
UPDATE |
--- src/main/webapp/WEB-INF/jsp/web/main/mainPage.jsp
+++ src/main/webapp/WEB-INF/jsp/web/main/mainPage.jsp
... | ... | @@ -11,6 +11,7 @@ |
| 11 | 11 |
<script src="/publish/js/swiper.min.js"></script> |
| 12 | 12 |
|
| 13 | 13 |
<script type="text/javascript"> |
| 14 |
+var blineCode = "${blineCode}";
|
|
| 14 | 15 |
|
| 15 | 16 |
$(document).ready(function() {
|
| 16 | 17 |
// http => https 로 이동 |
... | ... | @@ -258,7 +259,7 @@ |
| 258 | 259 |
eventYn = true; |
| 259 | 260 |
</c:if> |
| 260 | 261 |
|
| 261 |
- if(payCount < 1 && eventYn){//결제내역이 하나도 없고, 이벤트가 진행중이면 팝업 호출
|
|
| 262 |
+ if(payCount < 1 && eventYn && blineCode == 'N'){//결제내역이 하나도 없고, 이벤트가 진행중이면 팝업 호출
|
|
| 262 | 263 |
remoteEventPayPop(payCount); |
| 263 | 264 |
}else{//이벤트 대상자가 아니면 첫결제 이벤트 팝업은 안보여준다.
|
| 264 | 265 |
|
... | ... | @@ -941,7 +942,12 @@ |
| 941 | 942 |
alert("해당 이벤트가 종료되었습니다.");
|
| 942 | 943 |
location.href="<c:url value='/web/main/mainPage.do'/>"; |
| 943 | 944 |
|
| 944 |
- } |
|
| 945 |
+ }else if(returnData.resultSts == 'eventBline'){//B선 전송사 이용고객 => 이벤트대상 제외처리
|
|
| 946 |
+ |
|
| 947 |
+ alert("이벤트 대상자가 아닙니다.");
|
|
| 948 |
+ location.href="<c:url value='/web/main/mainPage.do'/>"; |
|
| 949 |
+ |
|
| 950 |
+ } |
|
| 945 | 951 |
|
| 946 | 952 |
} else if(status== 'fail'){
|
| 947 | 953 |
alert("이벤트 신청에 오류가 발생하였습니다.");
|
Add a comment
Delete comment
Once you delete this comment, you won't be able to recover it. Are you sure you want to delete this comment?