<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.style24.front.biz.dao.TsfRendererDao">

	<!-- 공통코드 목록 -->
	<select id="getCommonCodeList" parameterType="CommonCode" resultType="CommonCode">
		/* TsfRenderer.getCommonCodeList */
		SELECT CD
		     , CD_NM
		FROM   TB_COMMON_CODE
		WHERE  1 = 1
		<if test="useYn != null and useYn != ''">
		AND    USE_YN = #{useYn}
		</if>
		AND    CD_GB = #{cdGb}
		<if test="cd != null and cd != ''">
		AND    CD = #{cd}
		</if>
		<if test="cdNm != null and cdNm != ''">
		AND    CD_NM = #{cdNm}
		</if>
		<if test="cdDesc != null and cdDesc != ''">
		AND    CD_DESC = #{cdDesc}
		</if>
		<if test="exceptCds != null and exceptCds != ''">
		AND    CD NOT IN
		    <foreach collection="exceptCds" item="item" index="index"  open="(" close=")" separator=",">
		    #{item}
		    </foreach>
		</if>
		ORDER  BY CD_GB, DISP_ORD
	</select>

	<!-- 택배사명 목록 조회 -->
	<select id="getShipCompanyList" resultType="CommonCode">
		/* TsaDelivery.getShipCompanyList */
		SELECT SHIP_COMP_CD  AS CD
		     , SHIP_COMP_NM  AS CD_NM
		FROM   TB_SHIP_COMPANY
		WHERE  1 = 1
		AND    USE_YN = 'Y'
		AND    SWT_SHIP_COMP_CD IS NOT NULL
	</select>
</mapper>