...
|
...
|
@@ -45,9 +45,6 @@ class NewsaleData |
|
|
*/
|
|
|
public static function getNewProducts($gender, $channel, $order = 's_t_desc', $limit = 60, $page = 1)
|
|
|
{
|
|
|
// 构建url地址列表
|
|
|
$urlList = array();
|
|
|
|
|
|
$param = Yohobuy::param();
|
|
|
$param['method'] = 'app.search.newProduct';
|
|
|
$param['gender'] = $gender;
|
...
|
...
|
@@ -82,7 +79,6 @@ class NewsaleData |
|
|
*/
|
|
|
public static function selectNewSaleProducts($gender, $brand, $sort, $color, $size, $price, $p_d, $channel, $dayLimit = null, $limit = 60, $page = 1, $order = 's_t_desc')
|
|
|
{
|
|
|
|
|
|
$selectItems = array(
|
|
|
'gender' => $gender,
|
|
|
'brand' => $brand,
|
...
|
...
|
@@ -182,4 +178,30 @@ class NewsaleData |
|
|
return Yohobuy::get(Yohobuy::API_URL, $param);
|
|
|
}
|
|
|
|
|
|
|
|
|
/**
|
|
|
* 获取热销排行榜商品数据
|
|
|
*
|
|
|
* @param string $gender "1,3"表示男, "2,3"表示女, "1,2,3"表示全部
|
|
|
* @param string|null $sort 品类ID查询参数
|
|
|
* @param integer|null $tab_id Tab的ID
|
|
|
* @param integer $limit 查询返回的最大限制数, 默认为50
|
|
|
* @param integer $page 分页第几页, 默认第1页
|
|
|
* @return array 新品到着商品数据
|
|
|
*/
|
|
|
public static function getTopProducts($gender, $sort = null, $tab_id = null, $limit = 50, $page = 1)
|
|
|
{
|
|
|
$param = Yohobuy::param();
|
|
|
$param['method'] = 'app.search.top';
|
|
|
$param['gender'] = $gender;
|
|
|
!empty($sort) && $param['sort'] = $sort;
|
|
|
!empty($tab_id) && $param['tab_id'] = $tab_id;
|
|
|
$param['page'] = $page;
|
|
|
$param['limit'] = $limit;
|
|
|
|
|
|
$param['client_secret'] = Sign::getSign($param);
|
|
|
|
|
|
return Yohobuy::get(Yohobuy::API_URL, $param);
|
|
|
}
|
|
|
|
|
|
} |
...
|
...
|
|