롬복 추가 , [사용자] 결제관리 > 요금 사용내역 ==> 사용금액 표시 방법 변경 완료
This commit is contained in:
parent
ce3c41d453
commit
6dc7059184
9
pom.xml
9
pom.xml
@ -557,6 +557,15 @@
|
|||||||
<artifactId>KOMORAN</artifactId>
|
<artifactId>KOMORAN</artifactId>
|
||||||
<version>3.3.4</version>
|
<version>3.3.4</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
|
<!-- https://mvnrepository.com/artifact/org.projectlombok/lombok -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.projectlombok</groupId>
|
||||||
|
<artifactId>lombok</artifactId>
|
||||||
|
<version>1.18.24</version>
|
||||||
|
<scope>provided</scope>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
<!-- Komoran 형태소 분석기 -->
|
<!-- Komoran 형태소 분석기 -->
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
||||||
|
|||||||
65
src/main/java/itn/com/cmm/RestResponse.java
Normal file
65
src/main/java/itn/com/cmm/RestResponse.java
Normal file
@ -0,0 +1,65 @@
|
|||||||
|
package itn.com.cmm;
|
||||||
|
|
||||||
|
import org.springframework.http.HttpStatus;
|
||||||
|
|
||||||
|
import lombok.Builder;
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.NoArgsConstructor;
|
||||||
|
import lombok.Setter;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @fileName : RestResponse.java
|
||||||
|
* @author : 이호영
|
||||||
|
* @date : 2022.07.04
|
||||||
|
* @description : RestApi 응답에 사용할 Class
|
||||||
|
* @TODO :
|
||||||
|
* ===========================================================
|
||||||
|
* DATE AUTHOR NOTE
|
||||||
|
* ----------------------------------------------------------- *
|
||||||
|
* 2022.07.04 이호영 최초 생성
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
* • 1XX : 조건부 응답
|
||||||
|
* • 2XX : 성공
|
||||||
|
* • 3XX : 리다이렉션 완료
|
||||||
|
* • 4XX : 요청 오류
|
||||||
|
* • 500 : 서버 오류
|
||||||
|
*
|
||||||
|
* 참고 : https://km0830.tistory.com/33
|
||||||
|
*
|
||||||
|
* ====== 자주 사용하는 코드 =====
|
||||||
|
* 200 : Ok : 서버가 클라이언트의 요청을 성공적으로 처리, 웹 페이지에서는 페이지 요청이 정상적으로 완료 (Ok)
|
||||||
|
* 400 : Bad Request : 잘못 요청 (Bad Request)
|
||||||
|
* 401 : Unauthorized : 권한 없음, 예를 들면, 로그인 페이지가 필요한 페이지를 로그인 없이 접속하려는 경우 반환되는 코드 (인증 실패) (Unauthorized)
|
||||||
|
*
|
||||||
|
* */
|
||||||
|
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
|
@NoArgsConstructor
|
||||||
|
public class RestResponse {
|
||||||
|
|
||||||
|
private HttpStatus status;
|
||||||
|
|
||||||
|
private String msg;
|
||||||
|
|
||||||
|
private Object data;
|
||||||
|
|
||||||
|
|
||||||
|
@Builder
|
||||||
|
public RestResponse(HttpStatus status, String msg, Object data) {
|
||||||
|
this.status = status;
|
||||||
|
this.msg = msg;
|
||||||
|
this.data = data;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
@ -139,4 +139,5 @@ public interface MjonPayService {
|
|||||||
|
|
||||||
//누적 납부금액 조회 (후불회원이 사용금액을 실 납부한 금액 합산 - 미납 금액 제외한 총 합산 금액)
|
//누적 납부금액 조회 (후불회원이 사용금액을 실 납부한 금액 합산 - 미납 금액 제외한 총 합산 금액)
|
||||||
public String selectTotSumPaymentAfterPay(String userId) throws Exception;
|
public String selectTotSumPaymentAfterPay(String userId) throws Exception;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -2833,4 +2833,6 @@ public class MjonPayServiceImpl extends EgovAbstractServiceImpl implements MjonP
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -13,9 +13,11 @@ import java.nio.charset.Charset;
|
|||||||
import java.text.NumberFormat;
|
import java.text.NumberFormat;
|
||||||
import java.text.SimpleDateFormat;
|
import java.text.SimpleDateFormat;
|
||||||
import java.time.LocalDate;
|
import java.time.LocalDate;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Calendar;
|
import java.util.Calendar;
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
|
import java.util.HashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Locale;
|
import java.util.Locale;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
@ -39,12 +41,18 @@ import org.json.simple.JSONObject;
|
|||||||
import org.json.simple.parser.JSONParser;
|
import org.json.simple.parser.JSONParser;
|
||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
import org.slf4j.LoggerFactory;
|
import org.slf4j.LoggerFactory;
|
||||||
|
import org.springframework.http.HttpStatus;
|
||||||
|
import org.springframework.http.MediaType;
|
||||||
|
import org.springframework.http.ResponseEntity;
|
||||||
import org.springframework.stereotype.Controller;
|
import org.springframework.stereotype.Controller;
|
||||||
import org.springframework.ui.Model;
|
import org.springframework.ui.Model;
|
||||||
import org.springframework.ui.ModelMap;
|
import org.springframework.ui.ModelMap;
|
||||||
import org.springframework.web.bind.annotation.ModelAttribute;
|
import org.springframework.web.bind.annotation.ModelAttribute;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMethod;
|
||||||
import org.springframework.web.bind.annotation.RequestParam;
|
import org.springframework.web.bind.annotation.RequestParam;
|
||||||
|
import org.springframework.web.bind.annotation.ResponseBody;
|
||||||
import org.springframework.web.multipart.MultipartFile;
|
import org.springframework.web.multipart.MultipartFile;
|
||||||
import org.springframework.web.multipart.MultipartHttpServletRequest;
|
import org.springframework.web.multipart.MultipartHttpServletRequest;
|
||||||
import org.springframework.web.servlet.HandlerMapping;
|
import org.springframework.web.servlet.HandlerMapping;
|
||||||
@ -59,6 +67,7 @@ import egovframework.rte.ptl.mvc.tags.ui.pagination.PaginationInfo;
|
|||||||
import itn.com.cmm.ComDefaultCodeVO;
|
import itn.com.cmm.ComDefaultCodeVO;
|
||||||
import itn.com.cmm.EgovMessageSource;
|
import itn.com.cmm.EgovMessageSource;
|
||||||
import itn.com.cmm.LoginVO;
|
import itn.com.cmm.LoginVO;
|
||||||
|
import itn.com.cmm.RestResponse;
|
||||||
import itn.com.cmm.service.EgovCmmUseService;
|
import itn.com.cmm.service.EgovCmmUseService;
|
||||||
import itn.com.cmm.service.FileVO;
|
import itn.com.cmm.service.FileVO;
|
||||||
import itn.com.cmm.util.DateUtils;
|
import itn.com.cmm.util.DateUtils;
|
||||||
@ -66,6 +75,8 @@ import itn.com.cmm.util.MJUtil;
|
|||||||
import itn.com.cmm.util.RedirectUrlMaker;
|
import itn.com.cmm.util.RedirectUrlMaker;
|
||||||
import itn.com.cmm.util.StringUtil;
|
import itn.com.cmm.util.StringUtil;
|
||||||
import itn.com.utl.fcc.service.EgovStringUtil;
|
import itn.com.utl.fcc.service.EgovStringUtil;
|
||||||
|
import itn.let.fax.admin.service.FaxStatVO;
|
||||||
|
import itn.let.mail.service.StatusResponse;
|
||||||
import itn.let.mjo.mjocommon.MjonCommon;
|
import itn.let.mjo.mjocommon.MjonCommon;
|
||||||
import itn.let.mjo.msg.service.MjonMsgService;
|
import itn.let.mjo.msg.service.MjonMsgService;
|
||||||
import itn.let.mjo.msg.service.MjonMsgVO;
|
import itn.let.mjo.msg.service.MjonMsgVO;
|
||||||
@ -2612,7 +2623,7 @@ public class MjonPayController {
|
|||||||
}
|
}
|
||||||
String userId = loginVO == null ? "" : EgovStringUtil.isNullToString(loginVO.getId());
|
String userId = loginVO == null ? "" : EgovStringUtil.isNullToString(loginVO.getId());
|
||||||
mjonMsgVO.setUserId(userId);
|
mjonMsgVO.setUserId(userId);
|
||||||
|
/*
|
||||||
{ // 충전캐시
|
{ // 충전캐시
|
||||||
String sumPayMoney = mjonPayService.selectAgentSumPayMoney(userId);
|
String sumPayMoney = mjonPayService.selectAgentSumPayMoney(userId);
|
||||||
model.addAttribute("sumPayMoney", sumPayMoney);
|
model.addAttribute("sumPayMoney", sumPayMoney);
|
||||||
@ -2622,6 +2633,7 @@ public class MjonPayController {
|
|||||||
String sumPoint = mjonPayService.selectSumPoint(userId);
|
String sumPoint = mjonPayService.selectSumPoint(userId);
|
||||||
model.addAttribute("sumPoint", sumPoint);
|
model.addAttribute("sumPoint", sumPoint);
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
{ // 총 사용금액
|
{ // 총 사용금액
|
||||||
mjonPayVO.setUserId(userId);
|
mjonPayVO.setUserId(userId);
|
||||||
@ -2629,10 +2641,11 @@ public class MjonPayController {
|
|||||||
model.addAttribute("usedCashTotList", usedCashTotList);
|
model.addAttribute("usedCashTotList", usedCashTotList);
|
||||||
}
|
}
|
||||||
{ // 사용가능한 금액
|
{ // 사용가능한 금액
|
||||||
|
// mberManageVO.prePaymentYn 선불 후불 회원 구분으로 인해 select함
|
||||||
mberManageVO = mjonMsgDataService.selectMberManageInfo(userId);
|
mberManageVO = mjonMsgDataService.selectMberManageInfo(userId);
|
||||||
model.addAttribute("mberManageVO", mberManageVO);
|
model.addAttribute("mberManageVO", mberManageVO);
|
||||||
}
|
}
|
||||||
|
/*
|
||||||
{ // 발송건수
|
{ // 발송건수
|
||||||
mjonMsgVO.setReserveYn("N");
|
mjonMsgVO.setReserveYn("N");
|
||||||
List<MjonMsgVO> sendTotList = mjonMsgService.selectWithKakaoSendTotCnt(mjonMsgVO);
|
List<MjonMsgVO> sendTotList = mjonMsgService.selectWithKakaoSendTotCnt(mjonMsgVO);
|
||||||
@ -2644,7 +2657,7 @@ public class MjonPayController {
|
|||||||
List<MjonMsgVO> reservToList = mjonMsgService.selectWithKakaoSendTotCnt(mjonMsgVO);
|
List<MjonMsgVO> reservToList = mjonMsgService.selectWithKakaoSendTotCnt(mjonMsgVO);
|
||||||
model.addAttribute("reservToList", reservToList);
|
model.addAttribute("reservToList", reservToList);
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
{// 선거 후보자 정보 조회
|
{// 선거 후보자 정보 조회
|
||||||
MjonCandidateVO mjonCandidateVO = new MjonCandidateVO();
|
MjonCandidateVO mjonCandidateVO = new MjonCandidateVO();
|
||||||
if("p".equals(mberManageVO.getDept())) { //개인회원 선거 후보자 정보 불러오기
|
if("p".equals(mberManageVO.getDept())) { //개인회원 선거 후보자 정보 불러오기
|
||||||
@ -2723,8 +2736,12 @@ public class MjonPayController {
|
|||||||
|
|
||||||
return "/web/pay/PayUserSWList";
|
return "/web/pay/PayUserSWList";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 요금사용내역 하단 리스트 영역 신규 화면
|
* 요금사용내역 하단 리스트 영역 신규 화면
|
||||||
* 2023.12.22 우영두
|
* 2023.12.22 우영두
|
||||||
|
|||||||
@ -68,6 +68,16 @@ function payUserListAjax(pageNo){
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 탭 이동 시 화면에서 날짜체크 안하고
|
||||||
|
// back단에서 1년 날짜 지정함
|
||||||
|
function payUserListTabMoveAjax(pageNo){
|
||||||
|
|
||||||
|
document.listForm.pageIndex.value = pageNo;
|
||||||
|
var sendData= $(document.listForm).serializeArray();
|
||||||
|
$("#payUserListLoad").load("/web/member/pay/PayUserSWListAjax.do", sendData ,function(response, status, xhr){
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
function payUserTab(obj, pageType){
|
function payUserTab(obj, pageType){
|
||||||
|
|
||||||
@ -78,9 +88,46 @@ function payUserTab(obj, pageType){
|
|||||||
$tab.siblings("li.tab").find("button").removeAttr("title");
|
$tab.siblings("li.tab").find("button").removeAttr("title");
|
||||||
|
|
||||||
$("#pageType").val(pageType);
|
$("#pageType").val(pageType);
|
||||||
payUserListAjax(1);
|
payUserListTabMoveAjax(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
function getUsedCashTotList(){
|
||||||
|
var sendData = {
|
||||||
|
"startDate" : $("#startDate").val(),
|
||||||
|
"endDate" : $("#endDate").val()
|
||||||
|
};
|
||||||
|
|
||||||
|
console.log('sendData : ', sendData);
|
||||||
|
// url: '/web/member/pay/getUsedCashTotList.do',
|
||||||
|
|
||||||
|
$.ajax({
|
||||||
|
type:"POST",
|
||||||
|
url:"<c:url value='/web/member/pay/getUsedCashTotList.do' />",
|
||||||
|
data: sendData,
|
||||||
|
dataType:'json',
|
||||||
|
success:function(data){
|
||||||
|
console.log('data :: ', data);
|
||||||
|
if(data.status == 'OK') {
|
||||||
|
// 성공 처리
|
||||||
|
} else {
|
||||||
|
// 오류 처리
|
||||||
|
}
|
||||||
|
},
|
||||||
|
error: function(jqXHR, textStatus, errorThrown) {
|
||||||
|
console.error("AJAX Error:", textStatus, errorThrown);
|
||||||
|
console.error("Response:", jqXHR.responseText);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* 윈도우팝업 열기 */
|
/* 윈도우팝업 열기 */
|
||||||
function infoPop(pageUrl){
|
function infoPop(pageUrl){
|
||||||
document.infoPopForm.pageType.value = pageUrl;
|
document.infoPopForm.pageType.value = pageUrl;
|
||||||
@ -212,8 +259,9 @@ function fnRevDetailPop03(msgGroupId){
|
|||||||
</div>
|
</div>
|
||||||
<c:choose>
|
<c:choose>
|
||||||
<c:when test="${mberManageVO.prePaymentYn eq 'Y'}">
|
<c:when test="${mberManageVO.prePaymentYn eq 'Y'}">
|
||||||
|
<%-- <c:when test="${mberManageVO.prePaymentYn eq 'N'}"> --%>
|
||||||
<div class="hisroy_price">
|
<div class="hisroy_price">
|
||||||
<div class="hisroy_price_in">
|
<%-- <div class="hisroy_price_in">
|
||||||
<p>
|
<p>
|
||||||
<i></i>충전금액
|
<i></i>충전금액
|
||||||
</p>
|
</p>
|
||||||
@ -248,30 +296,32 @@ function fnRevDetailPop03(msgGroupId){
|
|||||||
</span>원
|
</span>원
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div> --%>
|
||||||
<div class="hisroy_price_in">
|
<div class="hisroy_price_in">
|
||||||
<p>
|
<p>
|
||||||
<i></i>사용금액
|
<i></i>사용금액
|
||||||
</p>
|
</p>
|
||||||
<c:forEach var="result" items="${usedCashTotList}" varStatus="status">
|
<%-- <c:forEach var="result" items="${usedCashTotList}" varStatus="status"> --%>
|
||||||
<div class="clearfix">
|
<div class="clearfix">
|
||||||
<p>
|
<p>
|
||||||
<c:if test="${result.divFlag eq 'CASH' }">
|
<%-- <c:if test="${result.divFlag eq 'CASH' }"> --%>
|
||||||
캐시
|
캐시
|
||||||
</c:if>
|
<%-- </c:if> --%>
|
||||||
<c:if test="${result.divFlag eq 'POINT' }">
|
<%-- <c:if test="${result.divFlag eq 'POINT' }"> --%>
|
||||||
포인트
|
<!-- 포인트 -->
|
||||||
</c:if>
|
<%-- </c:if> --%>
|
||||||
</p>
|
</p>
|
||||||
<p>
|
<p>
|
||||||
<span>
|
<span id="cashTxtId">
|
||||||
<fmt:formatNumber value="${result.totalPrice}" pattern="#,###.#"/>
|
<%-- ${cashTxt } --%>
|
||||||
|
<%-- <fmt:formatNumber value="${result.totalPrice}" pattern="#,###.#"/> --%>
|
||||||
|
<%-- <fmt:formatNumber value="${cashTxt}" pattern="#,###.#"/> --%>
|
||||||
</span>원
|
</span>원
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</c:forEach>
|
<%-- </c:forEach> --%>
|
||||||
</div>
|
</div>
|
||||||
<div class="hisroy_price_in">
|
<%-- <div class="hisroy_price_in">
|
||||||
<p>
|
<p>
|
||||||
<i></i>잔액
|
<i></i>잔액
|
||||||
</p>
|
</p>
|
||||||
@ -291,7 +341,7 @@ function fnRevDetailPop03(msgGroupId){
|
|||||||
</span>원
|
</span>원
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div> --%>
|
||||||
</div>
|
</div>
|
||||||
</c:when>
|
</c:when>
|
||||||
<c:otherwise>
|
<c:otherwise>
|
||||||
@ -424,7 +474,7 @@ function fnRevDetailPop03(msgGroupId){
|
|||||||
</div>
|
</div>
|
||||||
</c:otherwise>
|
</c:otherwise>
|
||||||
</c:choose>
|
</c:choose>
|
||||||
<div class="history_details">
|
<%-- <div class="history_details">
|
||||||
<p class="tType1_title"><img src="/publish/images/content/history_details_title.png" alt=""> 발송내역</p>
|
<p class="tType1_title"><img src="/publish/images/content/history_details_title.png" alt=""> 발송내역</p>
|
||||||
<div class="details_wrap">
|
<div class="details_wrap">
|
||||||
<table>
|
<table>
|
||||||
@ -480,7 +530,7 @@ function fnRevDetailPop03(msgGroupId){
|
|||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div> --%>
|
||||||
<form id="listForm" name="listForm" method="post">
|
<form id="listForm" name="listForm" method="post">
|
||||||
<input type="hidden" id="pageType" name="pageType" value="<c:out value='${searchVO.pageType}'/>"/>
|
<input type="hidden" id="pageType" name="pageType" value="<c:out value='${searchVO.pageType}'/>"/>
|
||||||
<input type="hidden" id="pageIndex" name="pageIndex" value="<c:out value='${searchVO.pageIndex}'/>"/>
|
<input type="hidden" id="pageIndex" name="pageIndex" value="<c:out value='${searchVO.pageIndex}'/>"/>
|
||||||
|
|||||||
@ -20,8 +20,19 @@
|
|||||||
<script src="/publish/js/content.js"></script>
|
<script src="/publish/js/content.js"></script>
|
||||||
<script>
|
<script>
|
||||||
$(document).ready(function(){
|
$(document).ready(function(){
|
||||||
|
|
||||||
|
|
||||||
|
// 사용금액 캐시 노출
|
||||||
|
var succPrice = '${totSuccSendPrice}';
|
||||||
|
console.log('succPrice.toLocaleString("ko-KR") : ', succPrice.toLocaleString('ko-KR'));
|
||||||
|
$('#cashTxtId').text(succPrice.replace(/\B(?=(\d{3})+(?!\d))/g, ','));
|
||||||
|
|
||||||
|
|
||||||
$('#startDate').val('${mjonMsgVO.startDate}');
|
$('#startDate').val('${mjonMsgVO.startDate}');
|
||||||
$('#endDate').val('${mjonMsgVO.endDate}');
|
$('#endDate').val('${mjonMsgVO.endDate}');
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* 목록 정렬 항목 아이콘 표시 */
|
/* 목록 정렬 항목 아이콘 표시 */
|
||||||
var searchSortCnd = $("[name='searchSortCnd']").val();
|
var searchSortCnd = $("[name='searchSortCnd']").val();
|
||||||
var searchSortOrd = $("[name='searchSortOrd']").val();
|
var searchSortOrd = $("[name='searchSortOrd']").val();
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user