fix(wms): 完成上架回写OMS入库业务单入库数量被跳过——getBusinessOrderNumber带ISSUE_STATUS!=4过滤, Feign回调先置执行单完成态后必查空, 致业务单in_quantity恒0
This commit is contained in:
@@ -217,8 +217,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<select id="getExecutionCount" resultType="java.lang.Integer" parameterType="java.lang.String">
|
<select id="getExecutionCount" resultType="java.lang.Integer" parameterType="java.lang.String">
|
||||||
select count(0) from "NGWL_TEST_OMS".EXECUTION_STOCK_IN_ORDER where BUSINESS_IN_ORDER_NUMBER = #{orderNumber} and ISSUE_STATUS != 4 and DEL_FLAG = 1
|
select count(0) from "NGWL_TEST_OMS".EXECUTION_STOCK_IN_ORDER where BUSINESS_IN_ORDER_NUMBER = #{orderNumber} and ISSUE_STATUS != 4 and DEL_FLAG = 1
|
||||||
</select>
|
</select>
|
||||||
|
<!-- 完成上架回写业务单号: 不带 ISSUE_STATUS != 4 —— completeUpShelf 中 Feign 回调(returnInResult)会先把执行单 ISSUE_STATUS 置 4,
|
||||||
|
若此处仍过滤完成态则必查空, 导致业务单/预约单的 in_quantity 回写被 null 守卫静默跳过(20260914修复);
|
||||||
|
limit 1 防数据异常多行导致单值查询抛 TooManyResultsException; 保留 DEL_FLAG=1(执行单反审归档时不回写) -->
|
||||||
<select id="getBusinessOrderNumber" resultType="java.lang.String" parameterType="java.lang.String">
|
<select id="getBusinessOrderNumber" resultType="java.lang.String" parameterType="java.lang.String">
|
||||||
select BUSINESS_IN_ORDER_NUMBER from "NGWL_TEST_OMS".EXECUTION_STOCK_IN_ORDER where IN_ORDER_NUMBER = #{orderNumber} and ISSUE_STATUS != 4 and DEL_FLAG = 1
|
select BUSINESS_IN_ORDER_NUMBER from "NGWL_TEST_OMS".EXECUTION_STOCK_IN_ORDER where IN_ORDER_NUMBER = #{orderNumber} and DEL_FLAG = 1 limit 1
|
||||||
</select>
|
</select>
|
||||||
<update id="updateOmsOrder">
|
<update id="updateOmsOrder">
|
||||||
update "NGWL_TEST_OMS".RESERVATION_STOCK_IN_ORDER set ISSUE_STATUS = #{status},in_quantity = #{shelvesQuantity},STORAGE_TIME = CURRENT_TIMESTAMP where IN_ORDER_NUMBER = #{orderNumber} and DEL_FLAG = 1
|
update "NGWL_TEST_OMS".RESERVATION_STOCK_IN_ORDER set ISSUE_STATUS = #{status},in_quantity = #{shelvesQuantity},STORAGE_TIME = CURRENT_TIMESTAMP where IN_ORDER_NUMBER = #{orderNumber} and DEL_FLAG = 1
|
||||||
|
|||||||
Reference in New Issue
Block a user