Authored by 周少峰

Merge branch 'release/4.6' of http://git.yoho.cn/fe/yohobuy-node into release/4.6

... ... @@ -218,11 +218,19 @@ exports.getSaleOthersData = (params, channel) => {
if (result[1].code === 200) {
finalResult.goods = productProcess.processProductList(result[1].data.product_list);
// 处理所有商品标题数据
finalResult.saleTitle = {};
// 顶部筛选条件
finalResult.filters = saleHandler.handleSaleFilterData(result[1].data.filter, params);
finalResult.saleTitle.name = '所有商品';
finalResult.saleTitle.count = result[1].data.total;
// 处理排序数据
finalResult.opts = saleHandler.handleSaleOptsData(params, result[1].data.total);
finalResult.totalCount = result[1].data.total;
finalResult.pager = saleHandler.handleSalePagerData(result[1].data.total, params);
// 处理所有商品标题数据
finalResult.saleTitle = {
name: '所有商品',
count: result[1].data.total
};
}
// 获取焦点图数据
... ... @@ -236,13 +244,6 @@ exports.getSaleOthersData = (params, channel) => {
// 获取左侧类目数据
finalResult.leftContent = saleHandler.handleSaleSortData(result[3].data.filter.group_sort, params);
// 顶部筛选条件
finalResult.filters = saleHandler.handleSaleFilterData(result[3].data.filter, params);
// 处理排序数据
finalResult.opts = saleHandler.handleSaleOptsData(params, result[3].data.total);
finalResult.totalCount = result[3].data.total;
finalResult.pager = saleHandler.handleSalePagerData(result[3].data.total, params);
}
if (!_.isEmpty(result[4])) {
... ... @@ -294,7 +295,9 @@ exports.getSaleDiscountData = (params, channel) => {
if (result[1].code === 200) {
finalResult.saleList = {};
finalResult.saleList.goods = productProcess.processProductList(result[1].data.product_list);
finalResult.saleList.totalCount = result[1].data.total;
finalResult.saleList.pager = saleHandler.handleSalePagerData(result[1].data.total, params);
finalResult.saleList.opts = saleHandler.handleSaleOptsData(params, result[1].data.total);
}
// 处理折扣专场标题 banner 数据
... ... @@ -311,9 +314,6 @@ exports.getSaleDiscountData = (params, channel) => {
// 处理分页等筛选信息
if (result[3].code === 200) {
finalResult.leftContent = saleHandler.handleSaleSortData(result[3].data.filter.group_sort, params);
finalResult.saleList.totalCount = result[3].data.total;
finalResult.saleList.pager = saleHandler.handleSalePagerData(result[3].data.total, params);
finalResult.saleList.opts = saleHandler.handleSaleOptsData(params, result[3].data.total);
}
... ... @@ -359,22 +359,19 @@ exports.getSalebreakingYardsData = (params, channel) => {
]).then(subResult => {
// 处理筛选条件数据
if (subResult[0].code === 200) {
finalResult.filters = saleHandler.handleSaleFilterData(
Object.assign(subResult[0].data.filter, {size: result[2].data}),
params);
finalResult.leftContent =
saleHandler.handleSaleSortData(subResult[0].data.filter.group_sort, params);
finalResult.opts = saleHandler.handleSaleOptsData(params, subResult[0].data.total);
finalResult.totalCount = subResult[0].data.total;
finalResult.pager = saleHandler.handleSalePagerData(subResult[0].data.total, params);
}
// 处理商品数据
if (subResult[1].code === 200) {
finalResult.filters = saleHandler.handleSaleFilterData(
Object.assign(subResult[1].data.filter, {size: result[2].data}),
params);
finalResult.goods = productProcess.processProductList(subResult[1].data.product_list);
finalResult.opts = saleHandler.handleSaleOptsData(params, subResult[1].data.total);
finalResult.totalCount = subResult[1].data.total;
finalResult.pager = saleHandler.handleSalePagerData(subResult[1].data.total, params);
// 处理所有商品标题数据
finalResult.saleTitle = {};
... ...
<div class="flash-sale clearfix">
{{> index/floor-header}}
<div class="flash-sale-list">
<ul class="g-list imgopacity clearfix">
{{#each imgHot}}
<li>
<a href="{{href}}" target= "_blank"><div class="flash-sale-banner">
<img src="{{image img 560 260}}"/></div>
<div class="flash-sale-bottom">
<p class="flash-sale-count">{{count}}折起</p>
<p class="flash-sale-name">{{name}}</p>
<p class="flash-sale-timer">timer</p>
<div class="flash-sale-logo">
<img src="{{image logo 100 60}}"/>
</div>
</div>
</a>
</li>
{{/each}}
</ul>
</div>
</div>
\ No newline at end of file
... ... @@ -21,7 +21,6 @@
{{/if}}
{{/ checkedConditions}}
{{#if ../goods}}
{{#if channel}}
<div class="channel section">
<span class="title">频道:</span>
... ... @@ -288,5 +287,4 @@
</div>
</div>
{{/if}}
{{/if}}
</div>
... ...
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.
This diff could not be displayed because it is too large.
... ... @@ -47,12 +47,20 @@ function setPageTime() {
var i, text, showTime;
for (i = 0; i < limitTime.length; i++) {
if (limitTime[i].time < 0) {
return;
}
limitTime[i].time -= 1000;
showTime = convertTime(limitTime[i].time);
if (showTime) {
text = showTime;
if (limitTime[i].pre) {
text = limitTime[i].pre + ' ' + text;
}
} else {
text = '活动已结束';
}
limitTime[i].dom.text(text);
}
}
... ...