CartData.php 603 Bytes
<?php

namespace LibModels\Wap\Home;

use Api\Sign;
use Api\Yohobuy;

/**
 * 购物车的数据模型
 *
 * @name CartData
 * @package LibModels/Wap/Home
 * @copyright yoho.inc
 * @version 1.0 (2015-11-09 13:58:27)
 * @author Gtskk <tttt6399998@126.com>
 */
class CartData
{

	/**
	 * 购物车数据
	 *
	 * @return array 购物车接口返回的数据
	 */
	public static function cartData($uid)
	{
		$param = Yohobuy::param();
		$param['method'] = 'app.Shopping.cart';
		$param['uid'] = $uid;
		$param['client_secret'] = Sign::getSign($param);

		return Yohobuy::get(Yohobuy::API_URL, $param);
	}

}