增加筛选状态为无的订单

This commit is contained in:
lulz1 2024-03-16 23:47:16 +08:00
parent c8a7699fe4
commit 1860392c2e
3 changed files with 8 additions and 10 deletions

View File

@ -30,6 +30,7 @@ import java.util.List;
import java.util.Optional;
import static com.chint.infrastructure.constant.CommonMessageConstant.SUCCESS;
import static com.chint.infrastructure.constant.OrderConstant.ORDER_EVENT_CHANGE;
@RestController
@RequestMapping("/OrderDetail")
@ -141,8 +142,6 @@ public class OrderDetailController {
HotelOrderDetail hotelOrderDetail = orderDetail.getHotelOrderDetail();
hotelOrderDetail.setOrderAmount(command.getAmount());
hotelOrderDetail.setOrderStatus("3");
hotelOrderDetail.setOrderNo(newOrderNo);
hotelOrderDetail.setDetailId(newOrderNo);
hotelOrderDetail.setCreateTime(command.getCreateTime());
@ -159,7 +158,6 @@ public class OrderDetailController {
CarOrderDetail carOrderDetail = orderDetail.getCarOrderDetail();
carOrderDetail.setOrderAmount(command.getAmount());
carOrderDetail.setOrderStatus("3");
carOrderDetail.setOrderNo(newOrderNo);
carOrderDetail.setDetailId(newOrderNo);
carOrderDetail.setCreateTime(command.getCreateTime());

View File

@ -17,7 +17,6 @@ import org.springframework.stereotype.Component;
import java.time.LocalDateTime;
import java.time.format.DateTimeFormatter;
import java.util.ArrayList;
import java.util.Comparator;
import java.util.List;
import java.util.Objects;
@ -145,17 +144,18 @@ public class OrderDetailQuery {
private Object processHotelOrderDetail(OrderDetail orderDetail, String systemType) {
HotelOrderDetail hotelOrderDetail = orderDetail.getHotelOrderDetail();
if (hotelOrderDetail != null &&
hotelOrderDetail.getOrderStatus() != null &&
systemType.equals(hotelOrderDetail.getBelongSysType())) {
String receiptsNum = hotelOrderDetail.getReceiptsNum();
if (receiptsNum != null) {
hotelOrderDetail.setReceiptsNum(regetReceiptsNum(receiptsNum));
}
// 仅当订单不是临时订单数据才加入结果列表
if (orderDetail.getOrderStatus() != null &&
!orderDetail.getSupplierName().equals(SUPPLIER_L_Y) &&
Double.parseDouble(hotelOrderDetail.getOrderAmount()) != 0) {
return hotelOrderDetail;
// 仅当订单是临时订单数据不加入结果列表
if (orderDetail.getSupplierName().equals(SUPPLIER_L_Y) &&
Double.parseDouble(hotelOrderDetail.getOrderAmount()) == 0) {
return null;
}
return hotelOrderDetail;
}
return null;
}

View File

@ -536,7 +536,7 @@ public class OrderDomainService {
String.valueOf(item.getItemId()),
data.getOrderNo(),
"-" + item.getRefundAmount(),
"4",
"3",
data.getRefundTime()
).sendToQueue();
}