Authored by 梁志锋

限购商品详情 跳转APP

... ... @@ -323,7 +323,7 @@ class DetailModel
self::procShowStatus($result, $showStatus, $isBeginSale);
$result['cartInfo']['limitProductCode'] = $baseInfo['limitProductCode'];
$result['cartInfo']['limitCodeUrl'] = self::getLimitCodeUrl($baseInfo['limitProductCode']);
$result['cartInfo']['limitCodeUrl'] = self::getLimitCodeUrl($baseInfo['limitProductCode'], $baseInfo['erpProductId']);
$result['cartInfo']['limitProductPay'] = Helpers::url('/cart/index/orderEnsure');
} else {
$result['cartInfo']['addToCartUrl'] = Helpers::url('/product/buy_' . $productId . '_' . $goodsId . '.html');
... ... @@ -879,11 +879,12 @@ class DetailModel
* 根据设备类型获得限购商品跳转app的url
*
* @param string $productCode 限购商品码
* @param string $skn 限购商品skn
* @return string 限购商品跳转url
*/
private static function getLimitCodeUrl($productCode)
private static function getLimitCodeUrl($productCode, $skn)
{
$url = 'yohoapp://yoho.app/openwith?limit_product_code=' . $productCode;
$url = 'yohoapp://yoho.app/openwith?limit_product_code=' . $productCode . '&product_skn=' . $skn;
// 苹果设备或者苹果IPAD
if (strstr($_SERVER['HTTP_USER_AGENT'], 'iPhone') || strstr($_SERVER['HTTP_USER_AGENT'], 'iPad')) {
... ...