Authored by xiaowei

Merge branch 'release/4.4' of http://git.dev.yoho.cn/web/yohobuy into release/4.4

... ... @@ -80,30 +80,30 @@ class SearchData
return 'http://192.168.102.216:8087/yohosearch/search.json';
case 'testing':
if ($type == 'sort') {
return 'http://10.66.100.4:8080/yohosearch/sortgroup.json';
return 'http://testing.yohoops.org/yohosearch/sortgroup.json';
}
elseif ($type == 'discount') {
return 'http://10.66.100.4:8080/yohosearch/discount.json';
return 'http://testing.yohoops.org/yohosearch/discount.json';
}
elseif ($type == 'recent') {
return 'http://10.66.100.4:8080/yohosearch/recent.json';
return 'http://testing.yohoops.org/yohosearch/recent.json';
}
elseif ($type == 'suggest') {
return 'http://10.66.100.4:8080/yohosearch/suggest.json';
return 'http://testing.yohoops.org/yohosearch/suggest.json';
}
else if($type == 'new-shelve') {
return 'http://10.66.100.4:8080/yohosearch/new-shelve.json';
return 'http://testing.yohoops.org/yohosearch/new-shelve.json';
}
elseif ($type == 'shop') {
return 'http://10.66.100.4:8080/yohosearch/shops.json';
return 'http://testing.yohoops.org/yohosearch/shops.json';
}
elseif ($type == 'search') {
return 'http://10.66.100.4:8080/yohosearch/search.json';
return 'http://testing.yohoops.org/yohosearch/search.json';
}
elseif ($type == 'brand') {
return 'http://10.66.100.4:8080/yohosearch/brand/list.json';
return 'http://testing.yohoops.org/yohosearch/brand/list.json';
}
return 'http://10.66.100.4:8080/yohosearch/search.json';
return 'http://testing.yohoops.org/yohosearch/search.json';
case 'developer':
default:
if ($type == 'sort') {
... ... @@ -594,4 +594,18 @@ class SearchData
{
return Yohobuy::get(self::getUrl(), $param);
}
/**
* 根据品牌id查询店铺列表接口
* @param type array $param
* @return type []
*/
public static function getQueryShopsByBrandId($brandId)
{
$param = Yohobuy::param();
$param['method'] = 'app.shop.queryShopsByBrandId';
$param['brand_id'] = $brandId;
$param['client_secret'] = Sign::getSign($param);
return Yohobuy::get(Yohobuy::API_URL, $param);
}
}
\ No newline at end of file
... ...
... ... @@ -596,7 +596,7 @@ class HelperSearch
//已选中品牌标签名
$existName = array();
foreach ($brand as $key => $v) {
if (!$v['brand_alif']) {
if (empty($v['brand_alif'])) {
$v['brand_alif'] = substr($v['brand_name_en'], 0, 1);
if (!$v['brand_alif']) {
$pinyin = self::pinYin($v['brand_name']);
... ...
... ... @@ -219,7 +219,7 @@
</p>
</td>
<td>{{price}}</td>
<td>{{coin}}</td>
<td>{{coin}}</td>
<td>{{num}}</td>
<td>{{sum}}</td>
</tr>
... ...

48.3 KB | W: | H:

48.3 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin

8.64 KB | W: | H:

8.64 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin
... ... @@ -106,6 +106,10 @@ class ShopModel
$searchCondition['userInput'] = empty($searchCondition['userInput']) ? array() : $searchCondition['userInput'];
$param = array_merge($searchCondition['userInput'], array('navBar' => 1));
$data['allGoods']['list'] = $result['goods'];
$data['allGoods']['navs'][] = array(
'name' => 'MORE',
'href' => self::$shopListUrl
);
$data['allGoods']['name'] = '全部商品 ALL';
$data['allGoods']['opts'] = $result['opts'];
$data['leftContent'] = isset($result['leftContent']) ? $result['leftContent'] : '';
... ... @@ -443,11 +447,44 @@ class ShopModel
*/
public static function goodsTabBar($data)
{
$result = array();
if (isset($data['resource_data'])) {
$result = $data['resource_data'];
$more = array(
'name' => 'MORE',
'href' => self::$shopListUrl
);
$result = array(
'hot' => array(),
'new' => array()
);
if (empty($data['resource_data'])) {
return $result;
}
if (isset($data['resource_data']['hot'])) {
foreach ($data['resource_data']['hot'] as $val) {
if (empty($val['url'])) {
continue;
}
$result['hot'][] = array(
'name' => $val['name'],
'href' => 'http://' . trim($val['url'], 'http://'),
);
}
}
if (isset($data['resource_data']['new'])) {
foreach ($data['resource_data']['new'] as $val) {
if (empty($val['url'])) {
continue;
}
$result['new'][] = array(
'name' => $val['name'],
'href' => 'http://' . trim($val['url'], 'http://'),
);
}
}
$result['hot'][] = $more;
$result['new'][] = $more;
return $result;
}
... ...