Authored by 周少峰

品牌小于等于10个,隐藏更多按钮

@@ -444,6 +444,10 @@ class HelperSearch @@ -444,6 +444,10 @@ class HelperSearch
444 if (self::checkSearch('brand')) { 444 if (self::checkSearch('brand')) {
445 return array(); 445 return array();
446 } 446 }
  447 + //品牌数量小于等于10,隐藏更多按钮
  448 + if (count($result['brandsShow']) < 11) {
  449 + $result['hideMore'] = true;
  450 + }
447 return $result; 451 return $result;
448 } 452 }
449 /** 453 /**
@@ -996,7 +1000,7 @@ class HelperSearch @@ -996,7 +1000,7 @@ class HelperSearch
996 */ 1000 */
997 public static function current() 1001 public static function current()
998 { 1002 {
999 - $url = explode('?', $_SERVER['REQUEST_URI']); 1003 + $url = explode('?', 'http://'.$_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI']);
1000 self::$listNav[0]['href'] = $url[0]; 1004 self::$listNav[0]['href'] = $url[0];
1001 return $url[0]; 1005 return $url[0];
1002 } 1006 }
@@ -1358,7 +1362,9 @@ class HelperSearch @@ -1358,7 +1362,9 @@ class HelperSearch
1358 //清除选中 1362 //清除选中
1359 $result['checkedConditions']['clearUrl'] = self::current(); 1363 $result['checkedConditions']['clearUrl'] = self::current();
1360 //频道 1364 //频道
1361 - $result['channel'] = self::gender(self::$filter); 1365 + $result['channel'] = array();
  1366 + //性别
  1367 + $result['gender'] = self::gender(self::$filter);
1362 //品牌 1368 //品牌
1363 $result['brand'] = self::brand(self::$filter); 1369 $result['brand'] = self::brand(self::$filter);
1364 //价格 1370 //价格