From c8041ec0544bf122e6819e6bf698997ccbf30aaf Mon Sep 17 00:00:00 2001
From: yujian <yujian@163.com>
Date: 星期二, 10 十二月 2019 15:32:34 +0800
Subject: [PATCH] 小黄条

---
 fanli/src/main/java/com/yeshi/fanli/controller/client/v2/BrandControllerV2.java |   41 +++++++++++++++++++++++++++++++----------
 1 files changed, 31 insertions(+), 10 deletions(-)

diff --git a/fanli/src/main/java/com/yeshi/fanli/controller/client/v2/BrandControllerV2.java b/fanli/src/main/java/com/yeshi/fanli/controller/client/v2/BrandControllerV2.java
index df8b079..d68c890 100644
--- a/fanli/src/main/java/com/yeshi/fanli/controller/client/v2/BrandControllerV2.java
+++ b/fanli/src/main/java/com/yeshi/fanli/controller/client/v2/BrandControllerV2.java
@@ -45,6 +45,7 @@
 import com.yeshi.fanli.util.Constant;
 import com.yeshi.fanli.util.StringUtil;
 import com.yeshi.fanli.util.ThreadUtil;
+import com.yeshi.fanli.util.VersionUtil;
 import com.yeshi.fanli.util.factory.goods.GoodsDetailVOFactory;
 import com.yeshi.fanli.util.taobao.TaoBaoUtil;
 import com.yeshi.fanli.util.taobao.TaoKeApiUtil;
@@ -351,11 +352,17 @@
 	 */
 	@RequestMapping(value = "getList", method = RequestMethod.POST)
 	public void getList(AcceptData acceptData, Integer page, Long cid, Long uid, PrintWriter out) {
-		if (Constant.IS_TEST) {
-			getListV3(acceptData, page, cid, uid, out);
-			return;
+		if ("ios".equalsIgnoreCase(acceptData.getPlatform())) {
+			if (VersionUtil.greaterThan_2_1(acceptData.getPlatform(), acceptData.getVersion())) {
+				getListV3(acceptData, page, cid, uid, out);
+				return;
+			}
+		} else {
+			if (VersionUtil.greaterThan_2_0_2(acceptData.getPlatform(), acceptData.getVersion())) {
+				getListV3(acceptData, page, cid, uid, out);
+				return;
+			}
 		}
-		
 		
 		if (page == null || page < 1) {
 			out.print(JsonUtil.loadFalseResult("椤电爜涓嶆纭�"));
@@ -400,9 +407,16 @@
 	@RequestMapping(value = "getShopInfoV2", method = RequestMethod.POST)
 	public void getShopInfoV2(AcceptData acceptData, Integer page, Long id, Long uid, PrintWriter out) {
 		
-		if (Constant.IS_TEST) {
-			getShopInfoV3(acceptData, page, id, uid, out);
-			return;
+		if ("ios".equalsIgnoreCase(acceptData.getPlatform())) {
+			if (VersionUtil.greaterThan_2_1(acceptData.getPlatform(), acceptData.getVersion())) {
+				getShopInfoV3(acceptData, page, id, uid, out);
+				return;
+			}
+		} else {
+			if (VersionUtil.greaterThan_2_0_2(acceptData.getPlatform(), acceptData.getVersion())) {
+				getShopInfoV3(acceptData, page, id, uid, out);
+				return;
+			}
 		}
 		
 		if (id == null) {
@@ -563,9 +577,16 @@
 	 */
 	@RequestMapping(value = "getHistoryV2", method = RequestMethod.POST)
 	public void getHistoryV2(AcceptData acceptData, Integer page, Long uid, Integer type, PrintWriter out) {
-		if (Constant.IS_TEST) {
-			getHistoryV3(acceptData, page, uid, type, out);
-			return;
+		if ("ios".equalsIgnoreCase(acceptData.getPlatform())) {
+			if (VersionUtil.greaterThan_2_1(acceptData.getPlatform(), acceptData.getVersion())) {
+				getHistoryV3(acceptData, page, uid, type, out);
+				return;
+			}
+		} else {
+			if (VersionUtil.greaterThan_2_0_2(acceptData.getPlatform(), acceptData.getVersion())) {
+				getHistoryV3(acceptData, page, uid, type, out);
+				return;
+			}
 		}
 		
 		if (type == null) {

--
Gitblit v1.8.0