...
|
...
|
@@ -19,13 +19,27 @@ class GradeData |
|
|
* @return array 接口返回的会员等级数据
|
|
|
*/
|
|
|
public function getGradeData($channel, $uid) {
|
|
|
|
|
|
$urlList = array();
|
|
|
//获取会员等级数据
|
|
|
$param = Yohobuy::param();
|
|
|
$param['yh_channel'] = $channel;
|
|
|
$param['uid'] = $uid;
|
|
|
$param['method'] = 'app.Passport.vip';
|
|
|
$param['client_secret'] = Sign::getSign($param);
|
|
|
return Yohobuy::get(Yohobuy::API_URL, $param);
|
|
|
$urlList['grade'] = Yohobuy::httpBuildQuery(Yohobuy::API_URL,$param);
|
|
|
|
|
|
//获取用户基本信息数据(用来得到username)
|
|
|
$param = array();
|
|
|
$param = Yohobuy::param();
|
|
|
$param['gender'] = $gender;
|
|
|
$param['uid'] = $uid;
|
|
|
$param['yh_channel'] = $channel;
|
|
|
$param['method'] = 'app.passport.profile';
|
|
|
$param['client_secret'] = Sign::getSign($param);
|
|
|
$urlList['userProfile'] = Yohobuy::httpBuildQuery(Yohobuy::API_URL,$param);
|
|
|
|
|
|
return Yohobuy::getMulti($urlList);
|
|
|
//return Yohobuy::get(Yohobuy::API_URL, $param);
|
|
|
}
|
|
|
|
|
|
/**
|
...
|
...
|
@@ -44,18 +58,18 @@ class GradeData |
|
|
return Yohobuy::get(Yohobuy::API_URL, $param);
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* 获取用户基本信息数据
|
|
|
*/
|
|
|
public function getUserProfileData($gender, $uid, $channel) {
|
|
|
$param = Yohobuy::param();
|
|
|
$param['gender'] = $gender;
|
|
|
$param['uid'] = $uid;
|
|
|
$param['yh_channel'] = $channel;
|
|
|
$param['method'] = 'app.passport.profile';
|
|
|
$param['client_secret'] = Sign::getSign($param);
|
|
|
|
|
|
return Yohobuy::get("http://api.open.yohobuy.com/",$param);
|
|
|
}
|
|
|
// /**
|
|
|
// * 获取用户基本信息数据
|
|
|
// */
|
|
|
// public function getUserProfileData($gender, $uid, $channel) {
|
|
|
// $param = Yohobuy::param();
|
|
|
// $param['gender'] = $gender;
|
|
|
// $param['uid'] = $uid;
|
|
|
// $param['yh_channel'] = $channel;
|
|
|
// $param['method'] = 'app.passport.profile';
|
|
|
// $param['client_secret'] = Sign::getSign($param);
|
|
|
//
|
|
|
// return Yohobuy::get("http://api.open.yohobuy.com/",$param);
|
|
|
// }
|
|
|
|
|
|
} |
...
|
...
|
|