package com.eactive.eai.rms.onl.manage.rule.transform;

import java.util.HashMap;
import java.util.List;

import org.springframework.stereotype.Repository;

import com.eactive.eai.rms.common.base.SqlMapClientTemplateDao;

/**
 * The Class TransformDao.
 * <ul>
 * <li>1. Function :</li>
 * <li>2. Summary :</li>
 * <li>3. Notification :</li>
 * </ul>
 */
@Repository("transformMappingDao")
@SuppressWarnings("unchecked")
public class TransformMappingDao extends SqlMapClientTemplateDao {

//    private static final Logger logger = Logger.getLogger(TransformMappingDao.class);

    /**
     * 전문 레이아웃 매핑 리스트 조회
     * @param vo
     * @return
     * @throws Exception
     */
    public List<TransformVo> listTransformPage(TransformVo vo) throws Exception {    	
    	return (List<TransformVo>)template.queryForList("TransformMapping.listTransformPage", vo);
    }

    public int findTotalCount(TransformVo vo) {
        return (Integer) this.template.queryForObject(
            "TransformMapping.findTotalCount", vo);
    }


	public List<TransformVo> getRefMsgIDList(TransformVo vo) {
        return (List<TransformVo>) this.template.queryForList(
                "TransformMapping.getRefMsgIDList", vo);
	}

    public int deleteRefMsgID(HashMap<String,Object> vo) {
        return this.template.update("TransformMapping.RefMsgIDDelete", vo);
    }

    public int insertRefMsgID(HashMap<String,Object> vo) {
        return this.template.update("TransformMapping.RefMsgIDInsert", vo);
    }
	
	public int updateRefMsgID(TransformVo vo) {
        return this.template.update("TransformMapping.RefMsgIDUpdate", vo);
	}
	
	public List<TransformVo> getRefMsgInfo(TransformVo vo) {
        return (List<TransformVo>) this.template.queryForList(
                "TransformMapping.getRefMsgInfo", vo);
	}
	
	public String getSvcMotivUseDstcd(TransformVo vo) {
        return (String) this.template.queryForObject(
                "TransformMapping.getSvcMotivUseDstcd", vo);
	}
	
}
