<?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.zy.asrs.mapper.PlaMapper">
|
<select id="getStockStatisAll" resultType="com.zy.asrs.entity.Pla">
|
select brand, matnr,workshop, sum(weight_anfme) as weight
|
from asr_pla_detl
|
<where>
|
<if test="brand != null and brand != ''">
|
and brand = #{brand}
|
</if>
|
<if test="stime != null">
|
and pakin_time >= #{stime}
|
</if>
|
<if test="etime != null">
|
and pakin_time <= #{etime}
|
</if>
|
<if test="status != null and status != ''">
|
and status = #{status}
|
</if>
|
</where>
|
GROUP BY brand,matnr,workshop ORDER BY matnr,workshop
|
</select>
|
</mapper>
|