From f4a0f2acc63d7785eab108419a4e16f5f688cb95 Mon Sep 17 00:00:00 2001
From: yujian <yujian@163.com>
Date: 星期六, 18 一月 2020 12:06:27 +0800
Subject: [PATCH] 用户注册信息

---
 fanli/src/main/java/com/yeshi/fanli/dao/mybatis/order/CommonOrderMapper.java |  107 +++++++++++++++++++++++++++++++++++++++++++++++++----
 1 files changed, 99 insertions(+), 8 deletions(-)

diff --git a/fanli/src/main/java/com/yeshi/fanli/dao/mybatis/order/CommonOrderMapper.java b/fanli/src/main/java/com/yeshi/fanli/dao/mybatis/order/CommonOrderMapper.java
index 6198ab8..c8f7353 100644
--- a/fanli/src/main/java/com/yeshi/fanli/dao/mybatis/order/CommonOrderMapper.java
+++ b/fanli/src/main/java/com/yeshi/fanli/dao/mybatis/order/CommonOrderMapper.java
@@ -9,7 +9,9 @@
 
 import com.yeshi.fanli.dao.BaseMapper;
 import com.yeshi.fanli.entity.order.CommonOrder;
+import com.yeshi.fanli.entity.order.ESOrder;
 import com.yeshi.fanli.vo.order.CommonOrderVO;
+import com.yeshi.fanli.vo.order.OrderCountVO;
 
 public interface CommonOrderMapper extends BaseMapper<CommonOrder> {
 
@@ -25,7 +27,7 @@
 	List<CommonOrderVO> listUserOrder(@Param("start") long start, @Param("count") int count, @Param("uid") Long uid,
 			@Param("state") Integer state, @Param("type") Integer type, @Param("orderState") Integer orderState,
 			@Param("orderNo") String orderNo, @Param("startTime") String startTime, @Param("endTime") String endTime,
-			@Param("day") Integer day, @Param("source") Integer source);
+			@Param("day") Integer day, @Param("listSource") List<Integer> listSource);
 
 	/**
 	 * 缁熻鐢ㄦ埛璁㈠崟 骞惰鍗曞彿鍒嗙粍
@@ -38,7 +40,7 @@
 	long countUserOrder(@Param("uid") Long uid, @Param("state") Integer state, @Param("type") Integer type,
 			@Param("orderState") Integer orderState, @Param("orderNo") String orderNo,
 			@Param("startTime") String startTime, @Param("endTime") String endTime, @Param("day") Integer day,
-			@Param("source") Integer source);
+			@Param("listSource") List<Integer> listSource);
 
 	/**
 	 * 鍒ゆ柇閮ㄥ垎澶辨晥鐘舵��
@@ -79,15 +81,23 @@
 	Map<String, BigDecimal> countHistoryOrder(@Param("uid") Long uid, @Param("day") Integer day,
 			@Param("source") Integer source);
 
+	
+	/**
+	 * 缁熻鏈夋晥璁㈠崟鏁伴噺
+	 * @param uid
+	 * @return
+	 */
+	OrderCountVO getOrderCount(@Param("uid") Long uid, @Param("day")Integer day, @Param("listSource") List<Integer> listSource);
+	
 	/**
 	 * 鏄ㄦ棩鎬昏鍗�-鏍规嵁绾㈠寘绫诲瀷 鑷喘 閭�璇� 鍒嗕韩
 	 * 
 	 * @param uid
 	 * @return
 	 */
-	Map<String, BigDecimal> countByUidAndOrderState(@Param("uid") Long uid, @Param("type") Integer type,
+	long countUserOrderToApp(@Param("uid") Long uid, @Param("type") Integer type,
 			@Param("startTime") String startTime, @Param("endTime") String endTime, @Param("day") Integer day,
-			@Param("source") Integer source);
+			@Param("source") Integer source,@Param("state") Integer state, @Param("stateOrder") Integer stateOrder);
 
 	/**
 	 * 濂栭噾璁㈠崟鏁伴噺
@@ -174,7 +184,9 @@
 	List<CommonOrderVO> listQuery(@Param("start") long start, @Param("count") int count,
 			@Param("keyType") Integer keyType, @Param("key") String key, @Param("state") Integer state,
 			@Param("type") Integer type, @Param("orderState") Integer orderState, @Param("startTime") String startTime,
-			@Param("endTime") String endTime, @Param("source") Integer source);
+			@Param("endTime") String endTime, @Param("source") Integer source,
+			@Param("listShopId")List<Long> listShopId, @Param("listGoodsId")List<Long> listGoodsId,
+			@Param("minTime")Date minTime, @Param("money")BigDecimal money);
 
 	/**
 	 * 璁㈠崟鍒楄〃鏌ヨ(涓嶅寘鍚瓙璁㈠崟)
@@ -201,7 +213,9 @@
 	 */
 	long countQuery(@Param("keyType") Integer keyType, @Param("key") String key, @Param("state") Integer state,
 			@Param("type") Integer type, @Param("orderState") Integer orderState, @Param("startTime") String startTime,
-			@Param("endTime") String endTime, @Param("source") Integer source);
+			@Param("endTime") String endTime, @Param("source") Integer source,
+			@Param("listShopId")List<Long> listShopId, @Param("listGoodsId")List<Long> listGoodsId,
+			@Param("minTime")Date minTime, @Param("money")BigDecimal money);
 
 	long countQueryWithNoChild(@Param("keyType") Integer keyType, @Param("key") String key,
 			@Param("state") Integer state, @Param("type") Integer type, @Param("orderState") Integer orderState,
@@ -258,6 +272,16 @@
 	List<CommonOrder> listBySourceTypeAndTradeId(@Param("sourceType") int sourceType, @Param("tradeId") String tradeId);
 
 	/**
+	 * 鏍规嵁鏉ユ簮鍜屼氦鏄揑D鑾峰彇璁㈠崟鍒楄〃
+	 * 
+	 * @param sourceType
+	 * @param tradeIdList
+	 * @return
+	 */
+	List<CommonOrder> listBySourceTypeAndTradeIdList(@Param("sourceType") int sourceType,
+			@Param("tradeIdList") List<String> tradeIdList);
+
+	/**
 	 * 
 	 * @param sourceType
 	 * @param state
@@ -270,13 +294,80 @@
 	List<CommonOrder> listBySourceTypeAndStateAndThirdCrateTime(@Param("sourceType") int sourceType,
 			@Param("state") Integer state, @Param("minTime") Long minTime, @Param("maxTime") Long maxTime,
 			@Param("start") long start, @Param("count") int count);
-	
-	
+
 	/**
 	 * 鏍规嵁璁㈠崟鍙锋煡璇�
+	 * 
 	 * @param orderNO
 	 * @return
 	 */
 	List<CommonOrder> getByOrderNo(@Param("uid") Long uid, @Param("orderNo") String orderNo);
 
+	
+	/**
+	 * 鏍规嵁鐢ㄦ埛ID鏌ヨ
+	 * @param uid
+	 * @param stateList
+	 * @param start
+	 * @param count
+	 * @return
+	 */
+	List<CommonOrder> listByUid(@Param("uid")Long uid,@Param("stateList") List<Integer> stateList,@Param("start") long start,@Param("count") int count);
+
+	
+	/**
+	 * 鏌ヨ棣栫瑪鏈夋晥鍒拌处璁㈠崟
+	 * @param uid  
+	 * @param typeHB 绫诲瀷锛� 1鑷喘  2鍒嗕韩 3閭�璇�
+	 * @param typeDate 鏃ユ湡绫诲瀷锛� 3鏈湀 4涓婃湀
+	 * @return
+	 */
+	CommonOrderVO firstValidOrderByUid(@Param("uid") Long uid, @Param("typeHB") Integer typeHB,
+			@Param("typeDate") Integer typeDate);
+	
+	
+	/**
+	 * 鑾峰彇棣栫瑪鍒嗕韩璁㈠崟锛�
+	 * @param uid  
+	 * @return
+	 */
+	CommonOrder getFirstShareOrderByUid(@Param("uid") Long uid);
+	
+	/**
+	 * 缁熻璁㈠崟鍙峰埌璐﹂噾棰�
+	 * @param uid
+	 * @return
+	 */
+	BigDecimal getTotalRewardMoneyByOrderNoAndSourceType(@Param("orderNo") String orderNo, @Param("sourceType") Integer sourceType);
+	
+	/**
+	 * 缁熻24灏忔椂鏈夋晥鑷喘璁㈠崟
+	 * @param uid
+	 * @return
+	 */
+	long count24HValidOrderByUid(@Param("uid") Long uid, @Param("minTime") Date minTime);
+	
+	
+	/**
+	 * 鎼滅储璁㈠崟
+	 * @param start
+	 * @param count
+	 * @param uid
+	 * @param list
+	 * @return
+	 */
+	List<CommonOrderVO> searchOrderByUid(@Param("start") long start, @Param("count") int count, @Param("uid") Long uid,
+			@Param("list")List<ESOrder> list);
+
+	
+	/**
+	 * 鎼滅储璁㈠崟
+	 * @param start
+	 * @param count
+	 * @param uid
+	 * @param list
+	 * @return
+	 */
+	long countSearchOrderByUid(@Param("uid") Long uid, @Param("list")List<ESOrder> list);
+
 }
\ No newline at end of file

--
Gitblit v1.8.0