<?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.qs.mp.admin.mapper.TicketPackageMapper">

    <!-- 通用查询映射结果 -->
    <resultMap id="BaseResultMap" type="com.qs.mp.admin.domain.TicketPackage">
        <id column="pkg_id" property="pkgId" />
        <result column="box_id" property="boxId" />
        <result column="pkg_no" property="pkgNo" />
        <result column="start_sn" property="startSn" />
        <result column="end_sn" property="endSn" />
        <result column="status" property="status" />
        <result column="sale_status" property="saleStatus" />
        <result column="sale_qty" property="saleQty" />
        <result column="pkg_unit" property="pkgUnit" />
        <result column="created_time" property="createdTime" />
        <result column="updated_time" property="updatedTime" />
    </resultMap>

    <!-- 通用查询结果列 -->
    <sql id="Base_Column_List">
        pkg_id, box_id, pkg_no, start_sn, end_sn, status, sale_status, sale_qty, pkg_unit, created_time, updated_time
    </sql>


    <!-- 查询盲票包列表 -->
    <select id="listTicketPackageVO" resultType="com.qs.mp.admin.domain.vo.TicketPackageVO">
		select t1.* , t2.title
		from mp_ticket_package t1
		left join mp_ticket_box t2 on t1.box_id = t2.box_id
		${ew.customSqlSegment}
	</select>

</mapper>
