Authored by 沈志敏

Merge branch 'develop' of git.yoho.cn:fe/yohoblk-wap into develop

... ... @@ -7,7 +7,6 @@
'use strict';
const brandApi = require('./brand-api');
const logger = global.yoho.logger;
const _ = require('lodash');
const camelCase = global.yoho.camelCase;
... ... @@ -57,8 +56,6 @@ const getBrandListData = params => {
return brandApi.getBrandListOriginData(params).then(result => {
if (result.data) {
Object.assign(finalResult, handleBrandList(result.data.all_list));
} else {
logger.error('getBrandListOriginData api data is null');
}
return finalResult;
... ...
... ... @@ -6,7 +6,6 @@
*/
'use strict';
const logger = global.yoho.logger;
const editorialListApi = require('./list-api');
const camelCase = global.yoho.camelCase;
... ... @@ -27,8 +26,6 @@ const editorialList = params => {
},
code: 200
});
} else {
logger.error('getEitorialListData api no data');
}
return camelCase(finalResult);
... ...
... ... @@ -10,7 +10,10 @@ const testUid = 8039837; // 测试uid
const refund = {
refund(req, res) {
res.render('refund');
res.render('refund', {
module: 'me',
page: 'refund'
});
},
order(req, res, next) {
const uid = req.user.uid || 8050882;
... ...
... ... @@ -66,14 +66,10 @@ const getShopData = params => {
});
}
});
} else {
logger.error('getShopsDecoratorList api no data');
}
return finalResult;
});
} else {
logger.error('getShopInfoData api no data');
}
return finalResult;
});
... ... @@ -87,8 +83,6 @@ const getShopData = params => {
logger.info('brand has no shop');
}
return finalResult;
} else {
logger.error('getBrandInfoByDomain api no data');
}
return finalResult;
... ... @@ -121,13 +115,9 @@ const getBrandShopGoodsData = params => {
},
code: 200
};
} else {
logger.error('getBrandShopGoodsOriginData api no data');
}
return camelCase(finalResult);
});
} else {
logger.error('getBrandInfoByDomain api no data');
}
return camelCase(finalResult);
});
... ...
... ... @@ -274,14 +274,16 @@
tab
},
created() {
const self = this;
this.getCateList();
bus.$on('channel.change', function(page, channel) {
self.gender = channelTrans[channel].code;
self.cateNavLeftData = self.brandCate[channelTrans[channel].key];
self.cateNavRightData = self.cateNavLeftData ? self.cateNavLeftData[0].sub : [];
bus.$on('channel.change', (page, channel) => {
this.gender = channelTrans[channel].code;
this.cateNavLeftData = this.brandCate[channelTrans[channel].key];
this.cateNavRightData = this.cateNavLeftData ? this.cateNavLeftData[0].sub : [];
this.rightAll = {
sortId: this.cateNavLeftData[0].relationParameter.sort,
categoryName: this.cateNavLeftData[0].categoryName
};
});
}
};
... ...
... ... @@ -7,7 +7,7 @@
</div>
<div class="filter-params">
<ul class="filter-cates">
<li class="filter-cate" v-for="classify in config" v-if="typeof classify === 'object'" @click="entrySub($key)">
<li class="filter-cate" v-for="classify in config" v-if="showCate($key, classify)" @click="entrySub($key)">
<i class="icon icon-right right"></i>
<span class="filter-cate-label">{{$key | filter-en-cn }}</span>
<span class="filter-cate-val">{{showLabel($key)}}</span>
... ... @@ -55,6 +55,19 @@
}
},
methods: {
// 只显示 可选值 大于 1的 筛选项
// groupSort 特殊处理
showCate: function(cateName, cateVals) {
if (toString.call(cateVals) === '[object Array]') {
if (cateName === 'groupSort') {
// TODO
} else if (cateVals.length > 1) {
return true;
}
}
return false;
},
clearVals: function() {
// remove all value
this.$set('selected', {});
... ... @@ -127,6 +140,10 @@
<style>
@import "../../../scss/common/color";
.app.ios .filter {
padding-top: 40px;
}
.filter {
position: fixed;
z-index: 1001;
... ... @@ -185,6 +202,10 @@
.filter-cate-val {
float: right;
font-size: 28px;
max-width: 50%;
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
}
.filter-cate-val,
... ...
... ... @@ -116,12 +116,12 @@
});
reasonConfig.specialReasons = [];
res.data.specialExchangeReason.forEach(obj => reasonConfig.specialReasons.push(obj.id));
res.data.specialReturnReason.forEach(obj => reasonConfig.specialReasons.push(obj.id));
reasonConfig.reasons = [{
id: 0,
name: '请选择'
}].concat(res.data.exchangeReason);
reasonConfig.specialNotice = res.data.specialNoticeBo;
}].concat(res.data.returnReason);
reasonConfig.specialNotice = res.data.specialNotice;
this.list = res.data.goodsList;
this.$set('refundData', res.data);
... ...
<template>
<div class="top-box clearfix" v-bind:class='{"top-box-left" : this.$parent.$refs.filter.isVisible,"top-change" : topChange || !shareData.isBlkShop}' v-infinite-scroll="changeTopStatus()">
<div class="top-box clearfix" v-bind:class='{"top-change" : topChange || !shareData.isBlkShop}' v-infinite-scroll="changeTopStatus()">
<span class="icon icon-back back" @click="goBack()"></span>
<span class="brand-name" v-if="!shareData.isBlkShop">{{shareData.brandName}}</span>
<div class="right">
... ... @@ -54,10 +54,6 @@
}
}
.top-box-left {
left: -665px;
}
.top-change {
background-color: #fff;
color: #000;
... ...