123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255 |
- package com.caimei.mapper;
- import com.caimei.model.po.CmPayShopRecordPo;
- import com.caimei.model.po.UserSearchHistoryPo;
- import com.caimei.model.vo.*;
- import org.apache.ibatis.annotations.Mapper;
- import org.apache.ibatis.annotations.Param;
- import java.math.BigDecimal;
- import java.util.List;
- /**
- * Description
- *
- * @author : plf
- * @date : 2021/3/26
- */
- @Mapper
- public interface OrderMapper {
- /**
- * 查询
- *
- * @param userId
- * @param orderState
- * @return
- */
- List<OrderVo> findOrderList(@Param("userId") Integer userId, @Param("orderState") Integer orderState);
- /**
- * 查询物流详情
- *
- * @param orderId
- * @return
- */
- List<LogisticsBatchVo> findLogistics(Integer orderId);
- /**
- * 查询该主订单下所有子订单
- *
- * @param orderId
- * @return
- */
- List<ShopOrderVo> findAllShopOrder(Integer orderId);
- /**
- * 查询子订单下所有商品
- *
- * @param shopOrderId
- * @return
- */
- List<OrderProductVo> findOrderProduct(Integer shopOrderId);
- /**
- * 查询收款记录
- *
- * @param orderId
- * @return
- */
- List<DiscernReceiptVo> findDiscernReceipt(Integer orderId);
- /**
- * 查询订单收货地址
- *
- * @param orderId
- * @return
- */
- UserInfoVo findUserInfo(Integer orderId);
- /**
- * 查询订单信息
- *
- * @param orderId
- * @return
- */
- OrderVo findOrder(Integer orderId);
- /**
- * 查询已退货数量
- *
- * @param shopOrderId
- * @param productId
- * @return
- */
- Integer returnedPurchase(@Param("shopOrderId") Integer shopOrderId, @Param("productId") Integer productId);
- /**
- * 查询已取消发货数量
- *
- * @param shopOrderId
- * @param productId
- * @return
- */
- Integer actualCancelNum(@Param("shopOrderId") Integer shopOrderId, @Param("productId") Integer productId);
- /**
- * 查询退款记录
- *
- * @param orderId
- * @return
- */
- BigDecimal findReturnedPurchase(Integer orderId);
- /**
- * 查询批次物流信息
- *
- * @param shopOrderId
- * @param batchId
- * @return
- */
- List<LogisticsRecordVo> findLogisticsRecord(@Param("shopOrderId") Integer shopOrderId, @Param("batchId") Long batchId);
- /**
- * 物流信息
- *
- * @param batchId
- * @return
- */
- List<LogisticsInformationVo> findLogisticsInfo(Long batchId);
- /**
- * 更新物流状态
- *
- * @param orderId
- */
- void updateLogisticsBatch(Integer orderId);
- /**
- * 更新订单状态
- *
- * @param order
- */
- void updateOrderStatus(OrderVo order);
- /**
- * 逻辑删除主订单
- *
- * @param orderId
- */
- void deleteOrder(Integer orderId);
- /**
- * 逻辑删除子订单
- *
- * @param orderId
- */
- void deleteShopOrder(Integer orderId);
- /**
- * 逻辑删除订单收款记录
- *
- * @param orderId
- */
- void deleteReceiptOrderRelation(Integer orderId);
- /**
- * 逻辑删除收款记录
- *
- * @param id
- */
- void deleteDiscernReceipt(Integer id);
- /**
- * 查询付款记录
- *
- * @param shopOrderId
- * @return
- */
- List<CmPayShopRecordPo> findPayShopRecord(Integer shopOrderId);
- /**
- * 逻辑删除子订单付款记录
- *
- * @param shopOrderId
- */
- void deletePayShopRecord(Integer shopOrderId);
- /**
- * 逻辑删除付款记录
- *
- * @param payShopId
- */
- void updatePayShop(Integer payShopId);
- /**
- * 取消订单
- *
- * @param orderId
- */
- void cancelOrder(Integer orderId);
- /**
- * 查询相关商品名称订单
- *
- * @param searchWord
- * @param userId
- * @return
- */
- List<OrderVo> searchOrder(@Param("searchWord") String searchWord, @Param("userId") Integer userId);
- /**
- * 查询组织订单搜索历史记录
- *
- * @param userId
- * @return
- */
- List<String> getSearchHistoryList(Integer userId);
- /**
- * 删除订单搜索历史记录
- *
- * @param userId
- */
- void deleteSearchHistory(Integer userId);
- /**
- * 保存订单搜索历史记录
- *
- * @param searchHistoryPo
- */
- void insertHistory(UserSearchHistoryPo searchHistoryPo);
- /**
- * 查询订单关键字历史是否存在
- *
- * @param userId
- * @param searchWord
- * @return
- */
- Long getHistoryIdByWord(@Param("userId") Integer userId, @Param("searchWord") String searchWord);
- /**
- * 更新订单搜索历史记录
- *
- * @param historyRecord
- */
- void updateHistoryById(UserSearchHistoryPo historyRecord);
- /**
- * 删除10条以上的记录
- *
- * @param userId
- */
- void deleteHistoryByUserId(Integer userId);
- /**
- * 查询订单数量
- *
- * @param userId 用户id
- * @param status
- * @return
- */
- Integer findOrderCount(@Param("userId") Integer userId,@Param("status") int status);
- }
|