Authored by 徐祁xuqi

Merge branch 'release/4.5' of http://git.yoho.cn/fe/YOHOBUYWAP into release/4.5

... ... @@ -204,6 +204,7 @@ class PlusstarData
$result['getArticleByBrand'] = array();
$param = Yohobuy::param();
$param['brand_id'] = $brandInfo['data']['brand_id'];
$param['uid'] = $uid;
$param['udid'] = $udid;
$param['limit'] = 3;
$param['client_type'] = $clientType;
... ...
... ... @@ -36,7 +36,7 @@ class SearchData
// return 'http://101.200.31.165/yohosearch/search.json';
return 'http://192.168.10.64:8080/yohosearch/search.json';
case 'testing':
return 'http://192.168.102.216:8080/yohosearch/search.json';
return 'http://testing.yohoops.org/yohosearch/search.json';
case 'developer':
default:
return 'http://searchyohoops.yohobuy.com/yohosearch/search.json';
... ...
... ... @@ -354,7 +354,7 @@ class Helpers
$result['showTags'] = $showTag;
$result['img'] = isset($articleData['src']) ? self::getImageUrl($articleData['src'], 640, 640) : '';
//逛详情页app跳转url处理 20160601
$result['url'] = self::getUrlSafe($articleData['url']) . '&openby:yohobuy={"action":"go.h5","params":{"param":{"id":"' . $articleData['id'] . '"},"shareparam":{"id":"' . $articleData['id'] . '"},"share":"/guang/api/v1/share/guang","id":' . $articleData['id'] . ',"type":0,"url":"' .'https:'. self::url('/info/index', array(), 'guang') . '","islogin":"N"}}';
$result['url'] = self::getUrlSafe($articleData['url']) . '&openby:yohobuy={"action":"go.h5","params":{"param":{"id":"' . $articleData['id'] . '"},"shareparam":{"id":"' . $articleData['id'] . '"},"share":"/guang/api/v1/share/guang","id":' . $articleData['id'] . ',"type":1,"url":"' .'https:'. self::url('/info/index', array(), 'guang') . '","islogin":"N"}}';
//$result['url'] = $articleData['url']; //$isApp ? $articleData['url'] : self::url('/info/index', array('id' => $articleData['id']), 'guang');
if (strrpos($result['url'], 'feature.yoho.cn') || strrpos($result['url'], 'cdn.yoho.cn')) {
... ... @@ -389,7 +389,6 @@ class Helpers
}
//编辑人员 app跳转url处理 20160601
$articleData['author']['url'] = self::getUrlSafe($articleData['author']['url']).'&openby:yohobuy={"action":"go.h5","params":{"param":{"id":"' . $articleData['author']['author_id'] . '"},"share":"","id":' . $articleData['author']['author_id'] . ',"type":0,"islogin":"N","url":"' .'https:'.self::url('/author/index', array(), 'guang') . '"}}';
$articleData['author']['url'] = self::getUrlSafe($articleData['author']['url']);
$result['author'] = $articleData['author'];
if (isset($result['author']['avatar'])) {
$result['author']['avatar'] = strtr($result['author']['avatar'], array('http://' => '//'));
... ...
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
... ... @@ -197,14 +197,13 @@ function reMarginFooter(fixedElement) {
(function() {
var uid = getUid(),
hasParentBp = false, // 判断是否有父级埋点,如果有,点击子埋点,不处罚父埋点。
basicBpDataLength = 3;
var sendBpData,
basicBpDataLength = 3,
sendBpData,
bindBpEvent;
uid = uid === 0 ? '' : uid;
window._ozuid = uid;//暴露ozuid
window._ozuid = uid; // 暴露ozuid
if (window._yas) {
window._yas(1 * new Date(), '1.0.15', 'yohobuy_m', uid, '', '');
... ... @@ -219,25 +218,29 @@ function reMarginFooter(fixedElement) {
floor: bpIdArr[1],
data: bpIdArr[2]
};
window._yas.sendCustomInfo(jsonData, Boolean(parseInt(bpIdArr[3]) || 1));
if (window._yas.sendCustomInfo) {
window._yas.sendCustomInfo(jsonData, Boolean(parseInt(bpIdArr[3]) || 1));
}
}
};
// 绑定埋点点击事件
bindBpEvent = function() {
$(document).off('click').on('click', '.buriedpoint', function(e) {
$('.buriedpoint').off('click').on('click', function(e) {
var databpid = $(this).attr('data-bp-id') || '',
bpIdArr = databpid.split('_'),
hasParentBp = false;
bpIdArr = databpid.split('_');
var $target = $(e.target),
partentBpLength = $target.parents('.buriedpoint').length;
if ($(e.target).parents('.buriedpoint').length > 0) {
hasParentBp = true;
}
if (!hasParentBp && bpIdArr && bpIdArr.length >= basicBpDataLength) {
sendBpData(bpIdArr);
}
if ($target.hasClass('buriedpoint') && partentBpLength > 0 ||
partentBpLength >= 2) {
hasParentBp = true;
}
});
};
... ... @@ -250,7 +253,7 @@ function reMarginFooter(fixedElement) {
$(document).on('shouldSendBpData', function(e, dataPbId) {
var bpIdArr;
if (dataPbId && (dataPbId.length && dataPbId.length > 0)) {
if (dataPbId && dataPbId.length && dataPbId.length > 0) {
hasParentBp = false;
bpIdArr = dataPbId.split('_');
sendBpData(bpIdArr);
... ...
... ... @@ -68,6 +68,7 @@ $('#likeBtn').on('touchstart', function() {
$('#addtoCart').on('touchstart', function() {
$('.cart-bar').hide();
productCode && chosePanel.setLimitGoodModeWithSknId(productCode, skn);
chosePanel.show();
... ... @@ -81,3 +82,8 @@ $('#addtoCart').on('touchstart', function() {
return false;
});
$('#buyLimit').on('touchstart', function() {
tip.show('打开APP可抢购该商品哦~');
return false;
});
... ...
... ... @@ -40,7 +40,6 @@
}
.owner-info {
border-bottom: 1px solid #e0e0e0;
line-height: 1.5;
}
.range{
... ...
... ... @@ -68,12 +68,13 @@
text-overflow: ellipsis;
white-space: nowrap;
}
.brand-name {
width: 60%;
font-size: 28px;
width: 40%;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
position: absolute;
}
.brand-thumb {
... ... @@ -85,7 +86,6 @@
}
.entry {
width: 150px;
color: #999;
font-size: 28px;
float: right;
... ...
... ... @@ -14,6 +14,7 @@
.shop-back-img {
height: 100%;
width: 100%;
}
}
... ...
... ... @@ -38,10 +38,10 @@
</div>
<div id="load-more-info" class="load-more-info">
<div class="loading status">
<div class="loading status hide">
正在加载...
</div>
<span class="no-more status hide">没有更多啦</span>
<span class="no-more status">没有更多啦</span>
</div>
<input id="gender" type="hidden" value={{gender}}>
{{/ guang}}
... ...
... ... @@ -20,10 +20,10 @@
</div>
<div id="load-more-info" class="load-more-info">
<div class="loading status">
<div class="loading status hide">
正在加载...
</div>
<span class="no-more status hide">没有更多啦</span>
<span class="no-more status">没有更多啦</span>
</div>
{{#if tag}}
... ...
... ... @@ -152,7 +152,7 @@
{{/if}}
{{#if canBuyLimit}}
<a href="javascript:;" id="addtoCart" class="addto-cart">立即购买</a>
<a href="javascript:;" id="buyLimit" class="addto-cart">立即购买</a>
{{/if}}
{{#if noLimitCode}}
... ...
... ... @@ -17,7 +17,7 @@
<img class="brand-thumb" src={{thumb}}>
<span class="brand-name">{{name}}</span>
<span class="entry">
进入品牌
进入店铺
<i class="iconfont">&#xe614;</i>
</span>
</a>
... ...
... ... @@ -295,8 +295,11 @@ class UserModel
$brand['brandName'] = $val['brand_name'];
$brand['update'] = $val['new_product_num'];
$brand['discount'] = $val['product_discount_num'];
$brand['link'] = Helpers::url('', array(), $val['brand_domain']);
if ($val['brandOrShopType'] == 'brandOrShopType') {
$brand['link'] = Helpers::url('/product/index/brand', array('shop_id' => $val['shop_id']));
} else {
$brand['link'] = Helpers::url('', array(), $val['brand_domain']);
}
// 处理品牌产品
$product = array();
foreach ($val['new_product'] as $one) {
... ...
... ... @@ -189,14 +189,8 @@ class IndexController extends AbstractAction
// 构建资讯文章内容
if (!empty($article['data']['list']['artList'])) {
$build = array();
// foreach ($article['data']['list']['artList'] as $article) {
// $build[] = Helpers::formatArticle($article, true, $isApp, false, $uid);
// }
foreach ($article['data']['list']['artList'] as $articlekey =>$article) {
$build[$articlekey] = Helpers::formatArticle($article, true, $isApp, false, $uid);
if($this->isApp()){
$build[$articlekey]['collect']['url'] = Helpers::url('/author/index', array('id' => $id), 'guang');
}
foreach ($article['data']['list']['artList'] as $article) {
$build[] = Helpers::formatArticle($article, true, $isApp, false, $uid);
}
$data['guang']['infos'] = $build;
}
... ...
... ... @@ -4,6 +4,7 @@ use Action\AbstractAction;
use LibModels\Wap\Guang\PlusstarData;
use Plugin\Helpers;
use Plugin\Images;
use Plugin\UdpLog;
/**
* 明星品牌和原创品牌
... ... @@ -119,6 +120,7 @@ class PlusstarController extends AbstractAction
} catch (\Exception $e) {
// do nothing
}
UdpLog::info('==$brandInfo==', $brandInfo);
if (empty($brandInfo['getBrandInfo']['data']['brand_id'])) {
break;
}
... ...