Beispiel #1
0
 /**
  * 计算总价
  *
  * @param itemsList
  * @return
  */
 private double calculateTotalPrice(List<QueryHotelForWebSaleItems> itemsList) {
   double totalPrice = 0;
   for (QueryHotelForWebSaleItems item : itemsList) {
     totalPrice += item.getAgentReadComissionPrice();
   }
   return totalPrice;
 }
Beispiel #2
0
 private boolean judgeFavurable(List<QueryHotelForWebSaleItems> itemsList) {
   boolean flag = false;
   for (QueryHotelForWebSaleItems item : itemsList) {
     if (item.getFavourableFlag()) {
       flag = true;
       break;
     }
   }
   return flag;
 }
Beispiel #3
0
 /**
  * 更改结果集中的 价格
  *
  * @param itemsList
  * @param htlB2bIncrease
  */
 private List<QueryHotelForWebSaleItems> fillIncreasePrice(
     List<QueryHotelForWebSaleItems> itemsList, HtlB2bIncrease htlB2bIncrease) {
   for (QueryHotelForWebSaleItems item : itemsList) {
     if (null != item.getFellowDate() && null != htlB2bIncrease.getAbleSaleDate()) {
       if (item.getFellowDate().getTime() == (htlB2bIncrease.getAbleSaleDate().getTime())) {
         // if(item.getAgentReadComissionPrice() == 0) break;
         item.setSalePrice(htlB2bIncrease.getIncreasePrice());
         item.setAgentReadComissionPrice(htlB2bIncrease.getIncreasePrice()); // 设置佣金价
         item.setAgentReadComissionRate(0); // 返佣率设置为0
         item.setAgentReadComission(0); // 佣金额设置为0
         item.setCurrency(htlB2bIncrease.getCurrency());
       }
     }
   }
   return itemsList;
 }