From c833ab8f5968c755ded82eea5e8ce2aca841a0cb Mon Sep 17 00:00:00 2001
From: yujian <yujian@123.com>
Date: 星期五, 27 九月 2019 15:14:06 +0800
Subject: [PATCH] Merge branch 'div' of ssh://193.112.35.168:29418/fanli-server into div

---
 fanli/src/main/java/com/yeshi/fanli/controller/client/v2/SearchControllerV2.java |   12 ++++++++++--
 1 files changed, 10 insertions(+), 2 deletions(-)

diff --git a/fanli/src/main/java/com/yeshi/fanli/controller/client/v2/SearchControllerV2.java b/fanli/src/main/java/com/yeshi/fanli/controller/client/v2/SearchControllerV2.java
index d7c58aa..98395d6 100644
--- a/fanli/src/main/java/com/yeshi/fanli/controller/client/v2/SearchControllerV2.java
+++ b/fanli/src/main/java/com/yeshi/fanli/controller/client/v2/SearchControllerV2.java
@@ -181,7 +181,6 @@
 			}
 
 			JSONObject root = new JSONObject();
-
 			root.put("type", 2);
 			JSONObject data = new JSONObject();
 			data.put("title", text);
@@ -253,8 +252,17 @@
 					String pddId = PinDuoDuoUtil.getPDDGoodsId(text);
 					if (!StringUtil.isNullOrEmpty(pddId)) {
 						PDDGoodsDetail goods = PinDuoDuoApiUtil.getGoodsDetail(Long.parseLong(pddId));
-						if (goods != null)
+						if (goods != null) {
 							commonGoods = CommonGoodsFactory.create(goods);
+						} else {
+							type = 4;
+							goods = PinDuoDuoUtil.getPDDGoodsInfo(pddId);
+							if(goods != null) {
+								commonGoods = new CommonGoods();
+								commonGoods.setTitle(goods.getGoodsName());
+								commonGoods.setPicture(goods.getGoodsThumbnailUrl());
+							}
+						}
 					}
 				}
 			}

--
Gitblit v1.8.0