|
|
|
@ -14,6 +14,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
<result property="productId" column="product_id" />
|
|
|
|
|
<result property="planCode" column="plan_code" />
|
|
|
|
|
<result property="planDetailCode" column="plan_detail_code" />
|
|
|
|
|
<result property="saleorderCode" column="saleorder_code" />
|
|
|
|
|
<result property="totalAmount" column="total_amount" />
|
|
|
|
|
<result property="frozenAmount" column="frozen_amount" />
|
|
|
|
|
<result property="occupyAmount" column="occupy_amount" />
|
|
|
|
@ -68,6 +69,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
<if test="productId != null">product_id,</if>
|
|
|
|
|
<if test="planCode != null">plan_code,</if>
|
|
|
|
|
<if test="planDetailCode != null">plan_detail_code,</if>
|
|
|
|
|
<if test="saleorderCode != null">saleorder_code,</if>
|
|
|
|
|
<if test="totalAmount != null">total_amount,</if>
|
|
|
|
|
<if test="frozenAmount != null">frozen_amount,</if>
|
|
|
|
|
<if test="occupyAmount != null">occupy_amount,</if>
|
|
|
|
@ -87,6 +89,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
<if test="productId != null">#{productId},</if>
|
|
|
|
|
<if test="planCode != null">#{planCode},</if>
|
|
|
|
|
<if test="planDetailCode != null">#{planDetailCode},</if>
|
|
|
|
|
<if test="saleorderCode != null">#{saleorderCode},</if>
|
|
|
|
|
<if test="totalAmount != null">#{totalAmount},</if>
|
|
|
|
|
<if test="frozenAmount != null">#{frozenAmount},</if>
|
|
|
|
|
<if test="occupyAmount != null">#{occupyAmount},</if>
|
|
|
|
@ -110,6 +113,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
<if test="productId != null">product_id = #{productId},</if>
|
|
|
|
|
<if test="planCode != null">plan_code = #{planCode},</if>
|
|
|
|
|
<if test="planDetailCode != null">plan_detail_code = #{planDetailCode},</if>
|
|
|
|
|
<if test="saleorderCode != null">saleorder_code = #{saleorderCode},</if>
|
|
|
|
|
<if test="totalAmount != null">total_amount = #{totalAmount},</if>
|
|
|
|
|
<if test="frozenAmount != null">frozen_amount = #{frozenAmount},</if>
|
|
|
|
|
<if test="occupyAmount != null">occupy_amount = #{occupyAmount},</if>
|
|
|
|
@ -135,6 +139,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
</delete>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<select id="getProductStockTotalAmount" resultType="BigDecimal" parameterType="WmsProductStock">
|
|
|
|
|
select sum(total_amount) from wms_product_stock
|
|
|
|
|
<where>
|
|
|
|
@ -145,7 +156,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
|
|
|
|
|
|
|
<select id="selectProductStockByLocationAndBatch" resultMap="WmsProductStockResult">
|
|
|
|
|
<include refid="selectWmsProductStockVo"/>
|
|
|
|
|
where location_code = #{locationCode} and product_batch = #{productBatch}
|
|
|
|
|
where location_code = #{locationCode} and product_batch = #{productBatch} and stock_type = #{stockType}
|
|
|
|
|
</select>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|