package com.bonus.canteen.core.order.common.service;

import com.bonus.canteen.core.order.common.model.OrderDetail;
import com.bonus.canteen.core.order.common.vo.OrderDetailWithImage;
import com.bonus.canteen.core.order.common.vo.OrderGoodsNumVO;

import java.time.LocalDate;
import java.util.Collection;
import java.util.List;

public interface OrderDetailService {
   void saveList(Collection<OrderDetail> entityList);
//
//   void updateOrderDetailQuantity(Long detailId, LocalDate orderDate, Integer quantity, BigDecimal totalAmount, BigDecimal calcTotalAmount);

   void batchUpdateDetailRefundQuantity(List<OrderDetail> orderDetailList);

   void removeByOrderIds(List<Long> orderIds, Collection<LocalDate> orderDates);
//
//   void removeByDetailId(Long detailId, LocalDate orderDate);

   List<OrderDetail> getOrderDetailList(Long orderId, LocalDate orderDate);
//
   List<OrderDetail> getOrderDetailList(List<Long> orderIdList, Collection<LocalDate> orderDates);

   List<OrderDetail> getOrderDetailList(List<Long> orderIdList, Collection<LocalDate> orderDates, List<Integer> detailStateList);
//
//   List<OrderDetail> listByDetailIds(List<Long> detailIds, List<LocalDate> orderDates);
//
//   Map<Long, List<OrderDetailVO>> getDetailVOGroupByOrderIdList(List<Long> orderIdList, List<LocalDate> orderDateList);
//
//   Map<Long, List<OrderDetailVO>> getDetailVOGroupByOrderIdList(List<Long> orderIdList, List<LocalDate> orderDateList, boolean fillImage);
//
//   List<OrderDetailVO> listDetailVOByOrderIds(List<Long> orderIdList, List<LocalDate> orderDateList);
//
//   List<OrderDetailVO> listDetailVOByOrderIds(List<Long> orderIdList, List<LocalDate> orderDateList, boolean fillImage);
//
//   List<OrderDetail> getOrderDetailListForPrint(Long orderId, LocalDate orderDate);

   List<OrderGoodsNumVO> getQuantityByCustId(Long custId, LocalDate orderDate, Integer mealtimeType, List<Long> goodsIdList);

   void orderDetailHandler(OrderDetail orderDetail, boolean ifMember);

   <T extends OrderDetailWithImage> void fillOrderDetailImage(List<T> orderDetails);

//   <T extends OrderDetailWithMachine> void fillOrderDetailMachine(List<T> orderDetails);
}
