From d3abe5706d231a938ebf4b551208d69d11265736 Mon Sep 17 00:00:00 2001
From: yujian <yujian@163.com>
Date: 星期三, 01 一月 2020 17:22:06 +0800
Subject: [PATCH] 小程序

---
 fanli/src/main/java/com/yeshi/fanli/controller/client/v2/InviteControllerV2.java |   47 ++++++++++++++++++++++++++++++++++++++++++++---
 1 files changed, 44 insertions(+), 3 deletions(-)

diff --git a/fanli/src/main/java/com/yeshi/fanli/controller/client/v2/InviteControllerV2.java b/fanli/src/main/java/com/yeshi/fanli/controller/client/v2/InviteControllerV2.java
index fee5ff4..4b32346 100644
--- a/fanli/src/main/java/com/yeshi/fanli/controller/client/v2/InviteControllerV2.java
+++ b/fanli/src/main/java/com/yeshi/fanli/controller/client/v2/InviteControllerV2.java
@@ -211,7 +211,7 @@
 		}
 
 		boolean needVIPInfo = false;
-		if (VersionUtil.greaterThan_2_1(acceptData.getPlatform(), acceptData.getVersion()))
+		if (VersionUtil.greaterThan_2_0_5(acceptData.getPlatform(), acceptData.getVersion()))
 			needVIPInfo = true;
 
 		// 缁勭粐鏁版嵁
@@ -370,7 +370,7 @@
 	 */
 	@RequestMapping(value = "countMyTeam", method = RequestMethod.POST)
 	public void countMyTeam(AcceptData acceptData, long uid, PrintWriter out) {
-		JSONObject bossData = getBossInfo(acceptData, uid, threeSaleSerivce.getMyBoss(uid));
+		JSONObject bossData = getBossInfo(uid, threeSaleSerivce.getMyBoss(uid));
 		JSONObject resultData = new JSONObject();
 
 		long firstTeam = threeSaleSerivce.countFirstTeam(uid, 1);
@@ -423,6 +423,23 @@
 	}
 
 	/**
+	 * 鑾峰彇鐢ㄦ埛淇℃伅
+	 * @param acceptData
+	 * @param uid
+	 * @param out
+	 */
+	@RequestMapping(value = "getBossInfo", method = RequestMethod.POST)
+	public void getBossInfo(AcceptData acceptData, Long uid, PrintWriter out) {
+		if (uid == null || uid <= 0) {
+			out.print(JsonUtil.loadFalseResult("鐢ㄦ埛鏈櫥褰�"));
+			return;
+		}
+		JSONObject bossData = getBossInfo(uid, threeSaleSerivce.getMyBoss(uid));
+		out.print(JsonUtil.loadTrueResult(bossData));
+	}
+	
+	
+	/**
 	 * 涓婄骇淇℃伅缁勭粐
 	 * 
 	 * @param acceptData
@@ -430,7 +447,7 @@
 	 * @param threeSale
 	 * @return
 	 */
-	private JSONObject getBossInfo(AcceptData acceptData, long uid, ThreeSale threeSale) {
+	private JSONObject getBossInfo(long uid, ThreeSale threeSale) {
 		JSONObject bossData = new JSONObject();
 		if (threeSale != null && threeSale.getBoss() != null) {
 			UserInfo boss = threeSale.getBoss();
@@ -608,4 +625,28 @@
 			out.print(JsonUtil.loadFalseResult("閭�璇蜂俊鎭幏鍙栧け璐�"));
 		}
 	}
+	
+	/**
+	 * 绔欏唴淇℃彁閱掗槦鍛樻坊鍔犲井淇″彿
+	 * 
+	 * @param acceptData
+	 * @param uid
+	 * @param inviteId
+	 * @param out
+	 */
+	@RequestMapping(value = "tailorCode")
+	public void tailorCode(AcceptData acceptData, String callback, Long uid, PrintWriter out) {
+		if (uid == null) {
+			JsonUtil.printMode(out, callback, JsonUtil.loadFalseResult("鐢ㄦ埛id缂哄け"));
+			return;
+		}
+
+		JSONObject data = new JSONObject();
+		data.put("num", threeSaleSerivce.countFirstTeam(uid, 1));
+		data.put("limit", Constant.INVITE_CODRE_TAILOR_LIMIT);
+		JsonUtil.printMode(out, callback, JsonUtil.loadTrueResult(data));
+	}
+	
+	
+	
 }

--
Gitblit v1.8.0