...
|
...
|
@@ -103,6 +103,11 @@ class ShopProcess |
|
|
*/
|
|
|
private static function brandBrowse($data)
|
|
|
{
|
|
|
$brandNumber = count($data);
|
|
|
//少于2个不展示
|
|
|
if ($brandNumber < 2) {
|
|
|
return;
|
|
|
}
|
|
|
foreach ($data as $val) {
|
|
|
self::$shopData['brandList']['list'][] = array(
|
|
|
'url' => Helpers::url('', '', $val['brandDomain']),
|
...
|
...
|
@@ -110,7 +115,8 @@ class ShopProcess |
|
|
'brandName' => $val['brandName']
|
|
|
);
|
|
|
}
|
|
|
if (count($data) > 5) {
|
|
|
//大于5个返回更多品牌链接
|
|
|
if ($brandNumber > 5) {
|
|
|
self::$shopData['brandList']['url'] = Helpers::url('/product/index/allBrand', array('shop_id' => self::$shopId));
|
|
|
}
|
|
|
}
|
...
|
...
|
@@ -170,7 +176,7 @@ class ShopProcess |
|
|
{
|
|
|
if (isset($data['code']) && $data['code'] == 200 && !empty($data['data'])) {
|
|
|
$total = count($data['data']);
|
|
|
if ($total > 5) {
|
|
|
if ($total > 6) {
|
|
|
self::$shopData['shopCategory']['url'] = Helpers::url('/product/index/category', array('shop_id' => self::$shopId));
|
|
|
return;
|
|
|
}
|
...
|
...
|
|