作者 lyh

gx

@@ -139,11 +139,14 @@ class IndexController extends BaseController @@ -139,11 +139,14 @@ class IndexController extends BaseController
139 $product_image = []; 139 $product_image = [];
140 foreach ($productList as $k => $v){ 140 foreach ($productList as $k => $v){
141 $image = []; 141 $image = [];
142 - $image['title'] = $v['title'];  
143 if(!empty($v['thumb']) && !empty($v['thumb']['url'])){ 142 if(!empty($v['thumb']) && !empty($v['thumb']['url'])){
144 $image['image'] = getImageUrl($v['thumb']['url']); 143 $image['image'] = getImageUrl($v['thumb']['url']);
  144 + $image['title'] = $v['title'];
  145 + $product_image[] = $image;
  146 + }
  147 + if(count($product_image) > 7){
  148 + break;
145 } 149 }
146 - $product_image[] = $image;  
147 } 150 }
148 $data = [ 151 $data = [
149 'title'=>$keywordInfo['title'], 152 'title'=>$keywordInfo['title'],