File name
Commit message
Commit date
File name
Commit message
Commit date
File name
Commit message
Commit date
File name
Commit message
Commit date
File name
Commit message
Commit date
File name
Commit message
Commit date
package itn.let.module.base;
import java.math.BigDecimal;
import java.math.RoundingMode;
import java.util.List;
import javax.annotation.Resource;
import org.springframework.stereotype.Component;
import itn.let.mjo.msg.service.MjonMsgVO;
import itn.let.mjo.msgdata.service.impl.MjonMsgDataDAO;
import itn.let.uss.umt.service.MberManageVO;
/**
*
* @author : 이호영
* @fileName : PriceAndPoint.java
* @date : 2023.03.27
* @description : 금액 포인트 관련 module
* ===========================================================
* DATE AUTHOR NOTE
* ----------------------------------------------------------- *
* 2023.03.27 이호영 최초 생성
*
*
*
*/
@Component
public class PriceAndPoint {
@Resource(name="MjonMsgDataDAO")
private MjonMsgDataDAO mjonMsgDataDAO;
public String getBefCash(String userId) throws Exception {
MjonMsgVO mjonMsgVO = new MjonMsgVO();
mjonMsgVO.setUserId(userId);
return mjonMsgDataDAO.selectBeforeCashData(mjonMsgVO);
}
public String getBefPoint(String userId) throws Exception {
MjonMsgVO mjonMsgVO = new MjonMsgVO();
mjonMsgVO.setUserId(userId);
return mjonMsgDataDAO.selectBeforePointData(mjonMsgVO);
}
/**
* @methodName : getUserMoney
* @author : 이호영
* @date : 2023.03.30
* @description : 사용자 보유 잔액
* @param userId
* @return
* @throws Exception
*/
public BigDecimal getUserMoney(String userId) throws Exception {
MberManageVO mberManageVO = mjonMsgDataDAO.selectMberManageInfo(userId);
BigDecimal userMoney = new BigDecimal(mberManageVO.getUserMoney()).setScale(2, RoundingMode.HALF_EVEN);
return userMoney;
}
}