Merge remote-tracking branch 'origin/dev-ty1.2' into dev-ty1.2
This commit is contained in:
+2
-2
@@ -185,8 +185,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<select id="queryList" parameterType="com.mhd.basic.domain.storageLocation.repository.todo.StorageLocationDO" resultMap="StorageLocationResult">
|
||||
<include refid="selectStorageLocationPo"/>
|
||||
<include refid="selectStorageLocationPo1"/>
|
||||
-- 按照创建时间倒序排序
|
||||
order by a.create_time desc
|
||||
-- 按照库位名称正序排序,名称相同时按创建时间倒序
|
||||
order by a.storage_location_name asc, a.create_time desc
|
||||
</select>
|
||||
|
||||
<select id="getStorageLocationCount" parameterType="com.mhd.basic.domain.storageLocation.repository.todo.StorageLocationDO" resultType="java.lang.Long">
|
||||
|
||||
+1
-1
@@ -100,6 +100,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<select id="queryList" parameterType="com.mhd.basic.domain.storageSection.repository.todo.StorageSectionDO" resultMap="StorageSectionResult">
|
||||
<include refid="selectStorageSectionPo"/>
|
||||
<include refid="selectStorageSectionPo1"/>
|
||||
order by a.create_time desc
|
||||
order by a.storage_name asc, a.create_time desc
|
||||
</select>
|
||||
</mapper>
|
||||
+12
-5
@@ -792,11 +792,18 @@ public class ReviewOrderApplicationService {
|
||||
|
||||
private void refreshReviewOrderStatus(Long reviewOrderId) {
|
||||
List<ReviewMaterialDetailPO> rows = reviewOrderMapper.queryDetailByReviewOrderId(reviewOrderId);
|
||||
// 业务口径:只有全部明细待复核=0 时,状态才置为 2;部分复核仍保持 1。
|
||||
// 状态 3 仅在 checkConfirm 中设置。
|
||||
boolean allReviewed = !CollectionUtils.isEmpty(rows)
|
||||
&& rows.stream().allMatch(r -> nz(r.getPendingReviewQty()).compareTo(BigDecimal.ZERO) == 0);
|
||||
Integer targetStatus = allReviewed ? 2 : 1;
|
||||
// ================== 旧口径:全部明细待复核=0 置 2,部分复核保持 1 ==================
|
||||
// // 业务口径:只有全部明细待复核=0 时,状态才置为 2;部分复核仍保持 1。
|
||||
// // 状态 3 仅在 checkConfirm 中设置。
|
||||
// boolean allReviewed = !CollectionUtils.isEmpty(rows)
|
||||
// && rows.stream().allMatch(r -> nz(r.getPendingReviewQty()).compareTo(BigDecimal.ZERO) == 0);
|
||||
// Integer targetStatus = allReviewed ? 2 : 1;
|
||||
// ================== 新口径:部分复核/全部复核完未确认均置 复核中(2),完全未复核保持 待复核(1) ==================
|
||||
// 只要有任意明细已复核数量>0(部分复核 / 全部复核完未确认)即为复核中(2);
|
||||
// 完全未复核(全部已复核=0)保持待复核(1)。状态 3 仅在 checkConfirm 中设置。
|
||||
boolean anyReviewed = !CollectionUtils.isEmpty(rows)
|
||||
&& rows.stream().anyMatch(r -> nz(r.getReviewedQty()).compareTo(BigDecimal.ZERO) > 0);
|
||||
Integer targetStatus = anyReviewed ? 2 : 1;
|
||||
|
||||
ReviewOrder order = reviewOrderMapper.selectById(reviewOrderId);
|
||||
if (order == null) {
|
||||
|
||||
Reference in New Issue
Block a user