NewOrderDao.java 7.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271
  1. package com.caimei.modules.order.dao;
  2. import com.caimei.modules.coupon.entity.CmCoupon;
  3. import com.caimei.modules.coupon.entity.CmCouponOrderRecord;
  4. import com.caimei.modules.order.entity.*;
  5. import com.caimei.modules.product.entity.CmPromotion;
  6. import com.caimei.modules.user.entity.NewCmSp;
  7. import com.thinkgem.jeesite.common.persistence.CrudDao;
  8. import com.thinkgem.jeesite.common.persistence.annotation.MyBatisDao;
  9. import org.apache.ibatis.annotations.Param;
  10. import java.util.Date;
  11. import java.util.List;
  12. import java.util.Set;
  13. @MyBatisDao
  14. public interface NewOrderDao extends CrudDao<NewOrder> {
  15. List<CmOrderPaymentVoucherVo> findVoucherVoOrderID(@Param("shopOrderId") Integer shopOrderId);
  16. List<CmVoucherImage> findCmVoucherImageoOrderID(@Param("id") Integer id);
  17. Integer updateClauseContent(NewOrder newOrder);
  18. NewOrder findByOrderID(@Param("orderID") Integer orderID);
  19. void updateStatus(NewOrder order);
  20. NewOrder getOrderByShopOrderID(@Param("shopOrderID") String shopOrderID);
  21. void updatePayStatus(@Param("payStatus") String payStatus, @Param("orderID") Integer orderID);
  22. List<NewOrder> findOrderList(NewOrder newOrder);
  23. Double findPaidOrderID(@Param("orderID") Integer orderID);
  24. List<CmPromotion> findPromotionsByIds(@Param("promotionsIds") Set promotionsIds);
  25. CmPromotion getDbPromotionsByOrderId(@Param("orderId") Integer orderId, @Param("promotionsId") Integer promotionsId);
  26. int insertPromotionsRecord(CmPromotion promotion);
  27. int updatePromotionsRecord(CmPromotion promotion);
  28. /**
  29. * 置为已收款已付款
  30. * @param orderId
  31. */
  32. void updatePayAndReceipt(Integer orderId);
  33. /**
  34. * 子订单置为已收款已付款
  35. * @param orderId
  36. */
  37. void updatePayStatusSon(Integer orderId);
  38. /**
  39. * 删除此订单下订单促销
  40. *
  41. * @param orderId
  42. */
  43. void deleterPomotionsOrder(Integer orderId);
  44. /**
  45. * 更新订单付款状态和0成本标识
  46. *
  47. * @param newOrder
  48. */
  49. void updateOrderStatus(NewOrder newOrder);
  50. /**
  51. * 获取上线协销人员,排除采美默认协销经理
  52. *
  53. * @return ServiceProvider
  54. */
  55. List<NewCmSp> findServiceProviderList();
  56. /**
  57. * 修改订单返佣标识
  58. *
  59. * @param orderId
  60. */
  61. void updateByRebateFlag(Integer orderId);
  62. /**
  63. * 查询商品资质文件
  64. *
  65. * @param recordId
  66. * @return
  67. */
  68. List<CmFile> findQualificationFile(String recordId);
  69. /**
  70. * 查询资质图片
  71. *
  72. * @param recordId
  73. * @return
  74. */
  75. List<String> findQualificationImage(Integer recordId);
  76. /**
  77. * 删除所有的资质图片
  78. *
  79. * @param recordId
  80. */
  81. void deleteQualificationImage(Integer recordId);
  82. /**
  83. * 保存资质图片
  84. *
  85. * @param recordId
  86. * @param image
  87. */
  88. void insertQualificationImage(@Param("recordId") Integer recordId, @Param("image") String image);
  89. /**
  90. * 删除商品资质文件
  91. *
  92. * @param recordId
  93. */
  94. void deleteQualificationFile(Integer recordId);
  95. /**
  96. * 保存商品资质文件
  97. *
  98. * @param recordId
  99. * @param fileName
  100. * @param ossName
  101. */
  102. void insertQualificationFile(@Param("recordId") Integer recordId, @Param("fileName") String fileName, @Param("ossName") String ossName);
  103. /**
  104. * 查询短链接是否存在
  105. *
  106. * @param shortLink
  107. * @return
  108. */
  109. Integer findBYShortLink(String shortLink);
  110. /**
  111. * 保存短链接信息
  112. *
  113. * @param markId 短信类型
  114. * @param shortLink 短链接
  115. * @param url 跳转地址
  116. */
  117. void insertShortLink(@Param("markId") int markId, @Param("shortLink") String shortLink, @Param("url") String url);
  118. /**
  119. * 保存短信发送条数
  120. *
  121. * @param markId
  122. * @param num
  123. */
  124. void updateSendNum(@Param("markId") int markId, @Param("num") int num);
  125. /**
  126. * 获取订单定金商品Id
  127. * @param orderID
  128. * @return
  129. */
  130. Integer getDepositOrderProductId(Integer orderID);
  131. /**
  132. * 定金商品撤销收款,用户余额扣除
  133. */
  134. void updateUserMoneyByUserId(@Param("payTotalFee")Double payTotalFee,@Param("userID") Integer userID);
  135. /**
  136. * 查询订单优惠券信息
  137. *
  138. * @param orderID
  139. * @return
  140. */
  141. CmCouponOrderRecord findOrderCouponRecord(Integer orderID);
  142. /**
  143. * 查询优惠券信息
  144. *
  145. * @param clubCouponId
  146. * @return
  147. */
  148. CmCoupon findClubCouponById(Integer clubCouponId);
  149. /**
  150. * 保存优惠券与订单关联信息
  151. *
  152. * @param orderRecord
  153. */
  154. void insertCouponOrderRecord(CmCouponOrderRecord orderRecord);
  155. /**
  156. * 更新优惠券与订单关联信息
  157. *
  158. * @param orderRecord
  159. */
  160. void updateCouponOrderRecord(CmCouponOrderRecord orderRecord);
  161. /**
  162. * 删除优惠券与订单关联信息
  163. *
  164. * @param id
  165. */
  166. void deleteCouponOrderRecord(Integer id);
  167. List<OrderReceiptRelationPo> getUndividedPaidReceipt(@Param("currentTime")String currentTime,@Param("shopOrderIds")String shopOrderIds);
  168. List<OrderProductVo> getOrderProductByOrderId(Integer orderId);
  169. Double getOrderProductPaidAmount(Integer orderProductId);
  170. ShopOrderVo getShopOrderListByOrderId(Integer shopOrderId);
  171. List<ShopOrderVo> getShopOrderByOrderId(Integer orderId);
  172. Double getPaidShipping(Integer orderId, Integer shopId);
  173. String getShopCommercialCode(Integer shopId);
  174. OrderVo getOrderByOrderId(Integer orderId);
  175. void insertSplitAccount(SplitAccountPo splitAccount);
  176. Date findSplitTime();
  177. void updateOnlinePayFlag(@Param("onlinePayFlag") Integer onlinePayFlag,@Param("orderId") Integer orderId);
  178. void updateBrokerage(@Param("shopOrderID")Integer shopOrderID ,@Param("brokerage")Double brokerage);
  179. Integer findSupport(Integer shopOrderId);
  180. List<OrderProductVo> getOrderProductByShopOrderId(Integer shopOrderId);
  181. List<SplitAccountPo> getSplitAccountList(String mbOrderId);
  182. Double getPaidShopAmount(Integer shopOrderId);
  183. void updateShopOrderByPayStatus(@Param("shopOrderId")Integer shopOrderId,@Param("paidShop") Double paidShop,@Param("payStatus") Integer payStatus);
  184. void insertPayShop(PayShopPo payShop);
  185. void insertPayShopRecord(PayShopRecordPo shopRecord);
  186. void updateOrderByPayStatus(@Param("orderId")Integer orderId, @Param("payStatus")Integer payStatus);
  187. void updateBySplitStatus(String mbOrderId);
  188. Integer findOnlinePay(Integer orderID);
  189. String findSplitCode(String shopOrderId);
  190. Double findPayAmount(String shopOrderId);
  191. Double findShouldPayShopAmount(String shopOrderId);
  192. void updateSettleStatus(@Param("shopOrderId")String shopOrderId,@Param("productType") Integer productType);
  193. void updateShopOrderSettleStatus(@Param("shopOrderId")String shopOrderId, @Param("settleStatus")Integer settleStatus);
  194. void insertSettleRecord(SettleRecord settleRecord);
  195. Double findSettleSum(String shopOrderId);
  196. List<SettleRecord> findSettleRecord(Integer orderID);
  197. Double findSettleAmount(Integer orderID);
  198. Integer findShopOrderSize(Integer orderID);
  199. Integer findSplitCount(Integer orderID);
  200. List<SplitAccountPo> getSplitRecord(Integer orderID);
  201. Integer getSplitTime(Integer shopOrderId);
  202. }