|
@@ -333,7 +333,7 @@
|
|
</select>
|
|
</select>
|
|
|
|
|
|
|
|
|
|
- <!--查询提货产品项信息-->
|
|
|
|
|
|
+ <!--查询审批产品项信息-->
|
|
<select id="listProductionItem" parameterType="Integer" resultType="ApprovalProductionItem">
|
|
<select id="listProductionItem" parameterType="Integer" resultType="ApprovalProductionItem">
|
|
SELECT
|
|
SELECT
|
|
api.item_id itemId,
|
|
api.item_id itemId,
|
|
@@ -483,23 +483,18 @@
|
|
<if test="itemShouldStorage != null" >
|
|
<if test="itemShouldStorage != null" >
|
|
item_should_storage = #{itemShouldStorage},
|
|
item_should_storage = #{itemShouldStorage},
|
|
</if>
|
|
</if>
|
|
- <if test="itemActualStorage != null" >
|
|
|
|
- item_actual_storage = #{itemActualStorage},
|
|
|
|
- </if>
|
|
|
|
<if test="itemLackNumber != null" >
|
|
<if test="itemLackNumber != null" >
|
|
item_lack_number = #{itemLackNumber}
|
|
item_lack_number = #{itemLackNumber}
|
|
</if>
|
|
</if>
|
|
</set>
|
|
</set>
|
|
- <where>
|
|
|
|
- <if test="itemId != null and itemId != ''">
|
|
|
|
- item_id = #{itemId}
|
|
|
|
- </if>
|
|
|
|
- </where>
|
|
|
|
|
|
+ WHERE
|
|
|
|
+ item_id = #{itemId}
|
|
</update>
|
|
</update>
|
|
<!-- 添加仓库入库记录-->
|
|
<!-- 添加仓库入库记录-->
|
|
<insert id="insertInventoryRecords" parameterType="ApprovalInventoryRecords">
|
|
<insert id="insertInventoryRecords" parameterType="ApprovalInventoryRecords">
|
|
INSERT INTO tb_rst_approval_inventory_records(
|
|
INSERT INTO tb_rst_approval_inventory_records(
|
|
approval_id,
|
|
approval_id,
|
|
|
|
+ item_id,
|
|
storage_state,
|
|
storage_state,
|
|
product_id,
|
|
product_id,
|
|
product_name,
|
|
product_name,
|
|
@@ -511,8 +506,31 @@
|
|
operating_time
|
|
operating_time
|
|
)
|
|
)
|
|
VALUES
|
|
VALUES
|
|
- (#{approvalId},#{storageState},#{productId}
|
|
|
|
|
|
+ (#{approvalId},#{itemId},#{storageState},#{productId}
|
|
,#{productName},#{colorName},#{shouldStorage}
|
|
,#{productName},#{colorName},#{shouldStorage}
|
|
,#{actualStorage},#{lackNumber},#{operatingAdminId},NOW())
|
|
,#{actualStorage},#{lackNumber},#{operatingAdminId},NOW())
|
|
</insert>
|
|
</insert>
|
|
|
|
+
|
|
|
|
+ <!--查询单个审批产品项信息-->
|
|
|
|
+ <select id="getProductionItem" parameterType="Integer" resultType="ApprovalProductionItem">
|
|
|
|
+ SELECT
|
|
|
|
+ api.item_id itemId,
|
|
|
|
+ api.production_id productionId,
|
|
|
|
+ api.product_id productId,
|
|
|
|
+ api.item_product_name itemProductName,
|
|
|
|
+ api.item_color_name itemColorName,
|
|
|
|
+ api.item_product_num itemProductNum,
|
|
|
|
+ api.item_brand_name itemBrandName,
|
|
|
|
+ api.item_product_model itemProductModel,
|
|
|
|
+ api.item_product_unit itemProductUnit,
|
|
|
|
+ api.item_product_box_number itemProductBoxNumber,
|
|
|
|
+ api.item_should_storage itemShouldStorage,
|
|
|
|
+ api.item_actual_storage itemActualStorage,
|
|
|
|
+ api.item_lack_number itemLackNumber,
|
|
|
|
+ api.item_create_time itemCreateTime,
|
|
|
|
+ api.item_update_time itemUpdateTime
|
|
|
|
+ from tb_rst_approval_production_item api
|
|
|
|
+ where
|
|
|
|
+ api.item_id = #{itemId}
|
|
|
|
+ </select>
|
|
</mapper>
|
|
</mapper>
|