Browse Source

2024年11月19日17:23:14

纪新园 1 year ago
parent
commit
ffc0731cfa

+ 4 - 2
blade-service/blade-purchase-sales/src/main/java/org/springblade/purchase/sales/service/impl/OrderItemsServiceImpl.java

@@ -294,10 +294,12 @@ public class OrderItemsServiceImpl extends ServiceImpl<OrderItemsMapper, OrderIt
 		List<OrderItems> orderItemsList = new ArrayList<>();
 		if (ObjectUtils.isNull(order.getOrderItemIds()) || order.getOrderItemIds().isEmpty()) {
 			orderItemsList = baseMapper.selectList(new QueryWrapper<OrderItems>().eq("pid", order.getId())
-				.eq("tenant_id", AuthUtil.getTenantId()).eq("is_deleted", 0));
+				.eq("tenant_id", AuthUtil.getTenantId()).eq("is_deleted", 0).last("ORDER BY sort"));
 		} else {
 			orderItemsList = baseMapper.selectList(new QueryWrapper<OrderItems>().eq("pid", order.getId())
-				.eq("tenant_id", AuthUtil.getTenantId()).eq("is_deleted", 0).in("id", order.getOrderItemIds()));
+				.eq("tenant_id", AuthUtil.getTenantId()).eq("is_deleted", 0)
+				.in("id", order.getOrderItemIds())
+				.last("ORDER BY sort"));
 		}
 		String itemIds = "";//商品id拼接
 		String updateUserIds = "";//修改人id拼接

+ 2 - 2
blade-service/blade-sales-part/src/main/java/org/springblade/salesPart/order/mapper/OrderItemsMapper.xml

@@ -231,7 +231,7 @@
             and not FIND_IN_SET(po.`status`,'退款请核,已取消,已退款,售后中')
         </if>
         <if test='saleDetailDto.isContain !=null and saleDetailDto.isContain !="" and saleDetailDto.isContain == "1"'>
-            and ( (FIND_IN_SET(po.bs_type,'XS,CG,RZCG') and FIND_IN_SET(po.`status`,'待确认,待发货,已发货,退款请核,已取消,已退款,售后中,已收货'))
+            and ( (FIND_IN_SET(po.bs_type,'XS,CG,RZCG') and FIND_IN_SET(po.`status`,'待确认,待发货,已发货,退款请核,已取消,已退款,售后中,已收货,录入'))
             or (FIND_IN_SET(po.bs_type,'TKXS,TKCG') and FIND_IN_SET(po.`status`,'已完成')) )
         </if>
         <if test='saleDetailDto.isContain !=null and saleDetailDto.isContain !="" and saleDetailDto.isContain == "0"'>
@@ -436,7 +436,7 @@
             and not FIND_IN_SET(po.`status`,'退款请核,已取消,已退款,售后中')
         </if>
         <if test='isContain !=null and isContain !="" and isContain == "1"'>
-          and ( (FIND_IN_SET(po.bs_type,'XS,CG,RZCG') and FIND_IN_SET(po.`status`,'待确认,待发货,已发货,退款请核,已取消,已退款,售后中,已收货'))
+          and ( (FIND_IN_SET(po.bs_type,'XS,CG,RZCG') and FIND_IN_SET(po.`status`,'待确认,待发货,已发货,退款请核,已取消,已退款,售后中,已收货,录入'))
               or (FIND_IN_SET(po.bs_type,'TKXS,TKCG') and FIND_IN_SET(po.`status`,'已完成')) )
         </if>
         <if test='isContain !=null and isContain !="" and isContain == "0"'>

File diff suppressed because it is too large
+ 589 - 468
blade-service/blade-sales-part/src/main/java/org/springblade/salesPart/ship/service/impl/ShipServiceImpl.java


+ 2 - 1
blade-service/blade-sales-part/src/main/java/org/springblade/salesPart/statistics/service/impl/StatisticsServiceImpl.java

@@ -673,7 +673,8 @@ public class StatisticsServiceImpl implements IStatisticsService {
 				map.put("amountCancellation", subTotalMoneyCancel.add(subTotalMoneyReturns));
 				map.put("costprieCancellation", costprieCancel.add(costprieReturns));
 				map.put("profitCancellation", profitCancel.add(profitReturns));
-			} else if ("XS".equals(saleDetailDto.getBsType()) || "CG".equals(saleDetailDto.getBsType())) {
+			} else if ("XS".equals(saleDetailDto.getBsType()) || "CG".equals(saleDetailDto.getBsType())
+				|| "RZCG".equals(saleDetailDto.getBsType())) {
 				map.put("goodsSum", goodsNumActual);
 				map.put("amount", subTotalMoneyActual);
 				map.put("costprie", costprieActual);

Some files were not shown because too many files changed in this diff