1.处理携程酒店数据

This commit is contained in:
wanglf3 2024-03-17 14:45:36 +08:00
parent 669a145aad
commit a610556b9a
2 changed files with 3 additions and 7 deletions

View File

@ -484,21 +484,18 @@ public class CTripOrderExtensionFactoryImpl implements OrderExtensionFactory {
if (paymentType.equals("ACCNT")) {
hotelOrderDetail.setPaymentType("0");
hotelOrderDetail.setCompanyAmount(paymentReceived.getAmount());
hotelOrderDetail.setPersonalAmount(KEEP_TWO_DECIMAL_ZERO);
} else {
hotelOrderDetail.setPaymentType("1");
hotelOrderDetail.setPersonalAmount(paymentReceived.getAmount());
hotelOrderDetail.setCompanyAmount(KEEP_TWO_DECIMAL_ZERO);
}
hotelOrderDetail.setPersonalRefundAmount(KEEP_TWO_DECIMAL_ZERO);
hotelOrderDetail.setCompanyRefundAmount(KEEP_TWO_DECIMAL_ZERO);
}
if (hotelOrderInfoEntity != null) {
hotelOrderDetail.setOrderNo(hotelOrderInfoEntity.getOrderID()); //订单号
hotelOrderDetail.setDetailId(hotelOrderInfoEntity.getOrderID());
@ -515,7 +512,6 @@ public class CTripOrderExtensionFactoryImpl implements OrderExtensionFactory {
hotelOrderDetail.setRoomCount(hotelOrderInfoEntity.getRoomQuantity()); //退订夜间数
hotelOrderDetail.setRoomTypeName(hotelOrderInfoEntity.getRoomName()); //房型
if (Double.parseDouble(hotelOrderInfoEntity.getAmount()) > 0) {
hotelOrderDetail.setOrderAmount(hotelOrderInfoEntity.getAmount());
// hotelOrderDetail.setRefundAmount(KEEP_TWO_DECIMAL_ZERO);

View File

@ -213,7 +213,7 @@ public class CTripTest {
@Test
void search() {
BaseContext.setCurrentUser(user);
SearchOrderResponse response = orderSearchRequest.searchOrderResponseByOrderId("29905600773");
SearchOrderResponse response = orderSearchRequest.searchOrderResponseByOrderId("31105372581");
System.out.println(response);
}