<?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.zjt.mapper.ProductionheaderMapper">
    <!-- 通用查询结果映射 -->
    <resultMap id="BaseResultMap" type="com.zjt.entity.Productionheader">
        <id column="variety_detail_id" jdbcType="FLOAT" property="varietyDetailId" />
        <result column="variety_id" jdbcType="VARCHAR" property="varietyId" />
        <result column="product_code" jdbcType="VARCHAR" property="productCode" />
        <result column="product_name" jdbcType="VARCHAR" property="productName" />
    </resultMap>
    <sql id="Base_Column_List">
        variety_detail_id, variety_id, product_code, product_name
    </sql>

    <select id="selectProductionheader"  resultMap="BaseResultMap">
        select  *
        from productionheader
        where variety_detail_id = #{varietyDetailId}
    </select>
</mapper>
