Authored by 郝肖肖

$key 不存在 用$articlekey I 服了 YOU

@@ -198,6 +198,7 @@ class PlusstarData @@ -198,6 +198,7 @@ class PlusstarData
198 $param = Yohobuy::param(); 198 $param = Yohobuy::param();
199 $param['brand_id'] = $brandInfo['data']['brand_id']; 199 $param['brand_id'] = $brandInfo['data']['brand_id'];
200 $param['udid'] = $udid; 200 $param['udid'] = $udid;
  201 + $param['uid'] = $uid;
201 $param['limit'] = 3; 202 $param['limit'] = 3;
202 $param['client_type'] = $clientType; 203 $param['client_type'] = $clientType;
203 $param['private_key'] = Yohobuy::$privateKeyList[$clientType]; 204 $param['private_key'] = Yohobuy::$privateKeyList[$clientType];
@@ -205,7 +206,6 @@ class PlusstarData @@ -205,7 +206,6 @@ class PlusstarData
205 206
206 $article = Yohobuy::get(Yohobuy::SERVICE_URL.self::URI_BRANDINFO_ARTICLE.'getArticleByBrand', $param); 207 $article = Yohobuy::get(Yohobuy::SERVICE_URL.self::URI_BRANDINFO_ARTICLE.'getArticleByBrand', $param);
207 $result['getArticleByBrand'] = empty($article['data']) ? array() : $article['data']; 208 $result['getArticleByBrand'] = empty($article['data']) ? array() : $article['data'];
208 -// file_put_contents('../../../../../../Desktop/app/n/getArticleByBrand.txt', var_export($result['getArticleByBrand'], true));  
209 209
210 // 是否收藏店铺 210 // 是否收藏店铺
211 $param = Yohobuy::param(); 211 $param = Yohobuy::param();
@@ -221,12 +221,6 @@ class PlusstarData @@ -221,12 +221,6 @@ class PlusstarData
221 }else{ 221 }else{
222 $result['getUidBrandFav'] = false; 222 $result['getUidBrandFav'] = false;
223 } 223 }
224 - // 相关资讯列表 (3篇)  
225 -// $result['getArticleByBrand'] = array();  
226 -// Yohobuy::yarConcurrentCall(Yohobuy::PRD_SERVICE_URL . self::URI_BRANDINFO_ARTICLE, 'getArticleByBrand', array($brandInfo['data']['brand_id'], 3, $udid), function($retval) use(&$result) {  
227 -// $result['getArticleByBrand'] = empty($retval) ? array() : $retval;  
228 -// file_put_contents('../../../../../../Desktop/app/o/getArticleByBrand.txt', var_export($retval, true));  
229 -// });  
230 224
231 // 新品到着列表 (6篇) 225 // 新品到着列表 (6篇)
232 $result['getNewProduct'] = array(); 226 $result['getNewProduct'] = array();
@@ -193,7 +193,7 @@ class IndexController extends AbstractAction @@ -193,7 +193,7 @@ class IndexController extends AbstractAction
193 // $build[] = Helpers::formatArticle($article, true, $isApp, false, $uid); 193 // $build[] = Helpers::formatArticle($article, true, $isApp, false, $uid);
194 // } 194 // }
195 foreach ($article['data']['list']['artList'] as $articlekey =>$article) { 195 foreach ($article['data']['list']['artList'] as $articlekey =>$article) {
196 - $build[$key] = Helpers::formatArticle($article, true, $isApp, false, $uid); 196 + $build[$articlekey] = Helpers::formatArticle($article, true, $isApp, false, $uid);
197 if($this->isApp()){ 197 if($this->isApp()){
198 $build[$articlekey]['collect']['url'] = Helpers::url('/author/index', array('id' => $id), 'guang'); 198 $build[$articlekey]['collect']['url'] = Helpers::url('/author/index', array('id' => $id), 'guang');
199 } 199 }