Authored by ccbikai

Merge branch 'release/1.0'

Showing 80 changed files with 995 additions and 876 deletions
... ... @@ -32,7 +32,7 @@ yoho币 | /me/mycurrency |
意见反馈 | /me/feedback |
关于我们 | /me/about |
物流详情 | /me/logistic?order_code=1609827614 |
退换货物流详情| /me/logistic?order_code=1609827614&type=refund|
退换货物流详情| /me/logistic?order_code=1609827614&id=3&type=refund|change
--------------------------------------------------------------------------------
### order 常亮
... ...
... ... @@ -28,6 +28,10 @@ const handleBrandList = origin => {
_.forEach(origin, (value, key) => {
let brands = [];
if (_.size(value) <= 0) {
return;
}
if (key === '0~9') {
hasNum = true;
numTemp = origin[key];
... ...
... ... @@ -11,7 +11,7 @@ const helpers = global.yoho.helpers;
* 个人中心主页
*/
const component = {
index: (req, res, next) => {
index: (req, res) => {
const uid = req.user.uid;
if (!uid && req.xhr) {
... ... @@ -21,17 +21,22 @@ const component = {
});
}
res.render('index', {
module: 'me',
page: 'index'
});
},
userdata: (req, res, next) => {
const uid = req.user.uid;
homeModel.getUserHomeData(uid).then(data => {
const proData = data[0];
const result = {
module: 'me',
page: 'index',
noLocalCSS: true,
head_ico: proData && proData.head_ico ? helpers.image(proData.head_ico, 174, 174) : '',
nickname: Object.keys(proData).length ? proData.nickname : '登录/注册'
headIco: proData && proData.head_ico ? helpers.image(proData.head_ico, 174, 174) : '',
nickName: Object.keys(proData).length ? proData.nickname : '登录/注册'
};
res.render('index', Object.assign(result, data[1]));
return res.json(global.yoho.camelCase(Object.assign(result, data[1])));
}).catch(next);
},
mydetails: (req, res, next) => {
... ...
... ... @@ -10,7 +10,7 @@ const notLoginTip = '抱歉,您暂未登录!';
const order = {
orders: (req, res) => {
const type = req.query.type;
const type = req.query.type || 1;
res.render('order', {
module: 'me',
... ... @@ -146,10 +146,13 @@ const order = {
// API- 订单-物流
getOrderLogisticdate: (req, res) => {
(req.query.type === 'exchange') && (req.query.type = 'change');
orderModel.getOrderLogisticdate({
uid: req.user.uid || '',
type: req.query.type || '',
order_code: req.query.orderCode
order_code: req.query.orderCode,
id: req.query.id
}).then(result => {
res.json(result);
});
... ...
... ... @@ -2,7 +2,6 @@
const api = global.yoho.API;
const serviceAPI = global.yoho.ServiceAPI;
const singleAPI = global.yoho.SingleAPI;
const Promise = require('bluebird');
const helpers = global.yoho.helpers;
/**
... ...
... ... @@ -92,6 +92,7 @@ exports.deleteOrder = (orderCode, uid) => {
* @param {[int]} order_code 订单号
* @param {[int]} uid 用户uid
* @param {[string]} type 退换货物流(退货:refund,换货:change)
* @param {[int]} id 退换货申请ID(type为refund | change,才有效)
* @return {[array]}
*/
exports.getOrderLogisticdate = (params) => {
... ...
... ... @@ -16,10 +16,6 @@ const refund = {
}).then(global.yoho.camelCase);
},
submitRefundData(uid, params) {
console.log(Object.assign({
method: 'app.refund.submit',
uid: uid,
}, params));
return api.post('', Object.assign({
method: 'app.refund.submit',
uid: uid,
... ... @@ -78,9 +74,7 @@ const refund = {
method: 'app.refund.getList'
}, param);
return api.get('', param, {
code: 200
}).then(global.yoho.camelCase);
return api.get('', param).then(global.yoho.camelCase);
},
/**
... ...
... ... @@ -19,6 +19,7 @@ const router = expressRouter();
// Your controller here
router.get('/me/', home.index); // 个人中心主页
router.get('/me/userdata', home.userdata); // 个人中心数据
router.get('/me/order', order.orders); // 订单
router.get('/me/order/detail', order.orderDetail);
... ...
<div class="my-page">
<div id="header" class="blk-header-wrap top-box">
<div class="blk-header">
<div class="blk-header-left">
<span class="icon icon-setting" id="setting"></span>
</div>
</div>
</div>
<div class="my-header">
<a class="user-info auth" id="user-info" href='/me/mydetails'>
<span class="user-avatar" {{#if head_ico}} style="background-image: url('{{head_ico}}');" {{/if}}></span>
</a>
<span class="username">{{nickname}}</span>
</div>
<div class="my-order">
<a class="order-title auth" href="/me/order?type=1">
我的订单
<span class="read-order">
查看全部订单 <span class="icon icon-right"></span>
</span>
</a>
<div class="order-type clearfix">
<a class="type-item auth" href="/me/order?type=2">
<span class="icon icon-wait-pay"></span>
<br>待付款
{{#if wait_pay_num}}
<span class="num">{{wait_pay_num}}</span>
{{/if}}
</a>
<a class="type-item auth" href="/me/order?type=3">
<span class="icon icon-wait-cargo"></span>
<br>待发货
{{#if wait_cargo_num}}
<span class="num">{{wait_cargo_num}}</span>
{{/if}}
</a>
<a class="type-item auth" href="/me/order?type=4">
<span class="icon icon-send-cargo"></span>
<br>待收货
{{#if send_cargo_num}}
<span class="num">{{send_cargo_num}}</span>
{{/if}}
</a>
<a class="type-item auth" href="/me/return">
<span class="icon icon-refund-exchange"></span>
<br>退换货
{{#if refund_exchange_num}}
<span class="num">{{refund_exchange_num}}</span>
{{/if}}
</a>
</div>
</div>
<div class="group-list">
<a class="glist-item auth" id="address">
地址管理
<span class="num">{{address_num}} <span class="icon icon-right"></span></span>
</a>
</div>
<div class="group-list">
<a class="glist-item auth" href="/me/collection">
收藏的商品
<span class="num">{{product_favorite_total}} <span class="icon icon-right"></span></span>
</a>
<a class="glist-item auth" href="/me/collection?tab=brand">
收藏的品牌
<span class="num">{{brand_favorite_total}} <span class="icon icon-right"></span></span>
</a>
</div>
<div class="group-list">
<a class="glist-item auth" href="/me/mycurrency">
YOHO 币
<span class="num">{{yoho_coin_num}} <span class="icon icon-right"></span></span>
</a>
</div>
<div class="group-list">
<a class="glist-item" href="/help">
帮助中心
<span class="num"><span class="icon icon-right"></span></span>
</a>
<a class="glist-item" href="/me/service">
在线客服
<span class="num"><span class="icon icon-right"></span></span>
</a>
</div>
<div id="home" class="my-page">
<home></home>
</div>
... ...
<div class="deal-main">
<section class="detail">
第一步:注册&登录
<h4>第一步:注册&登录</h4>
<ul>
<li>您可通过Yoho!Family账号进行登录</li>
<li>只需要一个手机号即可完成新账号注册</li>
</ul>
<br>
第二步:挑选心仪商品
<h4>第二步:挑选心仪商品</h4>
<ul>
<li>搜索关键字或者品牌名称,能找到您心仪的商品</li>
<li>根据商品分类和偏好进行筛选,能更快遇见您心仪的商品</li>
<li>将喜欢的商品放进购物车,以免错过</li>
</ul>
<br>
第三步:支付货款
<h4>第三步:支付货款</h4>
<ul>
<li>在购物车中点击“去结算”,商品在购物车中不保留库存</li>
<li>确认您的收货信息、发票以及货款,确认无误后提交订单进行结算</li>
<li>可以在“我的订单”查看订单物流进度</li>
</ul>
<br>
第四步:收货&退款
<h4>第四步:收货&退款</h4>
<ul>
<li>收到商品,点击“确认收货”</li>
<li>如您对商品满意我们深感荣幸,不满意您可以选择退货退款</li>
</ul>
<br>
<br>
若以上内容未解决您的问题,请联系在线客服为您解答。
<p>若以上内容未解决您的问题,请联系在线客服为您解答。</p>
</section>
</div>
... ...
<div class="deal-main">
<section class="detail">
1、Yoho!BLK全部采用顺丰速运,保证货物快速、安全地送达您的手中。
<br>
2、如您所在地区超出顺丰配送范围,我们将给您安排EMS进行配送。
<br>
3、在核对您订购的商品、邮寄地址、款项支付等信息无误后,Yoho!BLK会将货物及时发出
<br>
<br>
<ul>
<li>1、Yoho!BLK全部采用顺丰速运,保证货物快速、安全地送达您的手中。</li>
<li>2、如您所在地区超出顺丰配送范围,我们将给您安排EMS进行配送。</li>
<li>3、在核对您订购的商品、邮寄地址、款项支付等信息无误后,Yoho!BLK会将货物及时发出</li>
</ul>
<h4>订单已提交成功,什么时候可以发货?</h4>
订单提交成功后我们会尽快发货,订单当天16点前付款成功当天发货,其余订单次日发货。另外我们在北京、成都、广州设有中转仓,如果您是北京、天津、河北、四川、重庆、广东客户,您的商品将发往中转仓,订单当天15点前付款成功当天发往中转仓,其余订单次日发往中转仓,请您耐心等待。详细进度您可以进入“个人中心-我的订单”查看订单状态。商品发货后您也将收到短信通知,告知您快递公司以及快递单号。
<br>
<br>
<ul>
<li>订单提交成功后我们会尽快发货,订单当天16点前付款成功当天发货,其余订单次日发货。另外我们在北京、成都、广州设有中转仓,如果您是北京、天津、河北、四川、重庆、广东客户,您的商品将发往中转仓,订单当天15点前付款成功当天发往中转仓,其余订单次日发往中转仓,请您耐心等待。详细进度您可以进入“个人中心-我的订单”查看订单状态。商品发货后您也将收到短信通知,告知您快递公司以及快递单号。
</li>
</ul>
<h4>你们从哪里发货?多长时间可以到货?</h4>
我们的仓库在江苏南京,根据地域的不同,发货后江苏省内一般1-3天可以收到,江苏省外一般3-5天可以收到。如果在您订购完成后7天内商品仍没有送达,您可以直接与客服中心联系。需要说明的是:化妆品等液体商品,走的是陆运,会比普通商品晚2-3天左右,敬请谅解。
<br>
<br>
<ul>
<li>我们的仓库在江苏南京,根据地域的不同,发货后江苏省内一般1-3天可以收到,江苏省外一般3-5天可以收到。如果在您订购完成后7天内商品仍没有送达,您可以直接与客服中心联系。需要说明的是:化妆品等液体商品,走的是陆运,会比普通商品晚2-3天左右,敬请谅解。
</li>
</ul>
<h4>如何查看物流进度?</h4>
您可通过“个人中心-我的订单”查看物流进度,您也可以通过快递单号在各快递官网查询。
<br>
<br>
<span style="color:#ff0000;">温馨提醒:</span>快递派件过程中,如果我们联络您的时间超过7天未得到回复,此订单将被默认为您已经放弃订购。如果您对收货时间有特殊要求, 请您下单时在备注栏中详细注明。
<br>
<br>
若以上内容未解决您的问题,请联系在线客服
<ul>
<li>您可通过“个人中心-我的订单”查看物流进度,您也可以通过快递单号在各快递官网查询。</li>
<li><span style="color:#ff0000;">温馨提醒:</span>快递派件过程中,如果我们联络您的时间超过7天未得到回复,此订单将被默认为您已经放弃订购。如果您对收货时间有特殊要求, 请您下单时在备注栏中详细注明。</li>
</ul>
<p>若以上内容未解决您的问题,请联系在线客服</p>
</section>
</div>
... ...
<div class="deal-main">
<section class="detail">
<h4>商品到达以后可以当场验收商品吗?</h4>
商品支持当面验收,如配送人员不配合您可以选择拒收商品。商品送达后您可当场确认商品与您订购的是否一致。您在验收商品时如发现商品短缺、配送错误、包装破损、商品存在质量问题等,请您向配送人员指出,并当场拒收全部商品,并在送货单上注明原因。相应的赠品和优惠商品应同时拒收,并请您在24小时内与客服联系进一步处理。
<br>
<br>
<ul>
<li>
商品支持当面验收,如配送人员不配合您可以选择拒收商品。商品送达后您可当场确认商品与您订购的是否一致。您在验收商品时如发现商品短缺、配送错误、包装破损、商品存在质量问题等,请您向配送人员指出,并当场拒收全部商品,并在送货单上注明原因。相应的赠品和优惠商品应同时拒收,并请您在24小时内与客服联系进一步处理。
</li>
</ul>
<h4>可以由他人代为签收吗?</h4>
可以,非订货人本人签收的商品等同于订购人进行签收验货。
<br>
<br>
<ul>
<li>
可以,非订货人本人签收的商品等同于订购人进行签收验货。
</li>
</ul>
<h4>如签收后发现商品存在质量问题可以退货吗?</h4>
如您感觉商品存在质量问题您可以联系在线客服帮您做进一步处理。
<br>
<br>
<ul>
<li>
如您感觉商品存在质量问题您可以联系在线客服帮您做进一步处理。
</li>
</ul>
<h4>物流信息显示已签收,但我并未收到商品?</h4>
您可先确认商品是否放在门卫或者代收点,如没有您可以联系在线客服为您处理。
<br>
<br>
<ul>
<li>
您可先确认商品是否放在门卫或者代收点,如没有您可以联系在线客服为您处理。
</li>
</ul>
<h4>商品送到后我不想要了可以拒收吗?</h4>
可以。温馨提醒:无理由拒收需要您自行承担运费。
<br>
<br>
若以上内容未解决您的问题,请联系在线客服为您解答。
<ul>
<li>
可以。温馨提醒:无理由拒收需要您自行承担运费。
</li>
</ul>
<p>若以上内容未解决您的问题,请联系在线客服为您解答。</p>
</section>
</div>
... ...
<div class="deal-main">
<section class="detail">
<h4>服务承诺</h4>
如果您在购物过程中有任何建议或者意见,您可以通过在线客服与我们联系沟通,我们承诺在24小时内与您联系。
<br>
为了退货流程更方便,Yoho!BLK已推出自助退换货流程,请您登录后在个人中心中依提示进行在线退换货操作。如自助退换货有困难,可联系我们,客服专员会协助您完成退换货,我们将以最快的速度妥善为您解决。
<br>
<br>
<ul>
<li>如果您在购物过程中有任何建议或者意见,您可以通过在线客服与我们联系沟通,我们承诺在24小时内与您联系。</li>
<li>为了退货流程更方便,Yoho!BLK已推出自助退换货流程,请您登录后在个人中心中依提示进行在线退换货操作。如自助退换货有困难,可联系我们,客服专员会协助您完成退换货,我们将以最快的速度妥善为您解决。</li>
</ul>
<h4>服务时间</h4>
在线人工客服:8:00-24:00
<br>
400客服热线:8:00-22:30
<ul>
<li>在线人工客服:8:00-24:00</li>
<li>400客服热线:8:00-22:30</li>
</ul>
</section>
</div>
... ...
<div class="deal-main">
<section class="detail">
1、为节省您的宝贵时间及保证账户安全,现Yoho!BLK官网已开通《自助退换货》功能,您可在签收商品的7天内进入官网“我的订单”页面操作退货申请。
<br>
2、商品寄回时请您将商品连同发货单一并寄回(如无发货单,您可找张纸上注明订单编号,收货人姓名及手机号码),如您购买时索要发票,一经退货请将发票随商品一同寄回,如发票丢失将无法办理退货。
<br>
3、退换货地址:南京市江宁区江宁经济技术开发区苏源大道87号Yoho!Buy有货物流中心东一楼,Yoho!BLK仓库(收),邮编:211106。
<br>
4、退货中心收到寄回商品,检测后符合条件的,我们将在3个工作日内为您安排退款事宜。退款时间非退款到账时间,具体到账时间以各平台、银行具体情况为准。
<br>
<br>
具体操作流程如下:
<br>
第一步:进入“我的订单”—找到需要退换货的订单—点击”确认收货”
<br>
第二步:阅读退换货政策,根据您的实际情况选择退换货的原因,点击“提交退换货申请”
<br>
第三步:提交退换货申请成功后,会在24小时内确认您的申请,您可通过“我的退换货”查看退换货进度
<br>
<br>
<span style="color:#ff0000;">温馨提醒:</span>
<br>
1、因商品质量问题或平台原因导致而发生的退换货,Yoho!BLK将承担由此产生的配送费用;如因您个人原因退换货,请自行承担相关费用。
<br>
2、图片信息仅供参照,商品以实物为准。因拍摄灯光及不同显示器色差等问题可能造成商品图片与实物有一定色差,此情况不作为质量问题原因的退换货申请条件。
<br>
3、退换货商品须保持原样(原品牌包装完整,商品吊牌未剪,未穿洗),并有确保商品不会被二次损坏的包裹包装(包括包裹填充物及外包装箱或外包装袋),以确保商品在返回仓库的运输过程中不被损坏,使您的利益被充分保护。
<br>
4、已开具发票的订单,若发票未与商品一起寄回,则无法办理退货,换货无需寄回发票
<br>
<br>
若以上内容未解决您的问题,请联系在线客服为您解答。
<ul>
<li>1、为节省您的宝贵时间及保证账户安全,现Yoho!BLK官网已开通《自助退换货》功能,您可在签收商品的7天内进入官网“我的订单”页面操作退货申请。</li>
<li>2、商品寄回时请您将商品连同发货单一并寄回(如无发货单,您可找张纸上注明订单编号,收货人姓名及手机号码),如您购买时索要发票,一经退货请将发票随商品一同寄回,如发票丢失将无法办理退货。</li>
<li>3、退换货地址:南京市江宁区江宁经济技术开发区苏源大道87号Yoho!Buy有货物流中心东一楼,Yoho!BLK仓库(收),邮编:211106。</li>
<li>4、退货中心收到寄回商品,检测后符合条件的,我们将在3个工作日内为您安排退款事宜。退款时间非退款到账时间,具体到账时间以各平台、银行具体情况为准。</li>
</ul>
<h4>具体操作流程如下:</h4>
<ul>
<li>第一步:进入“我的订单”—找到需要退换货的订单—点击”确认收货”</li>
<li>第二步:阅读退换货政策,根据您的实际情况选择退换货的原因,点击“提交退换货申请”</li>
<li>第三步:提交退换货申请成功后,会在24小时内确认您的申请,您可通过“我的退换货”查看退换货进度</li>
</ul>
<h4><span style="color:#ff0000;">温馨提醒:</span></h4>
<ul>
<li>1、因商品质量问题或平台原因导致而发生的退换货,Yoho!BLK将承担由此产生的配送费用;如因您个人原因退换货,请自行承担相关费用。</li>
<li>2、图片信息仅供参照,商品以实物为准。因拍摄灯光及不同显示器色差等问题可能造成商品图片与实物有一定色差,此情况不作为质量问题原因的退换货申请条件。</li>
<li>3、退换货商品须保持原样(原品牌包装完整,商品吊牌未剪,未穿洗),并有确保商品不会被二次损坏的包裹包装(包括包裹填充物及外包装箱或外包装袋),以确保商品在返回仓库的运输过程中不被损坏,使您的利益被充分保护。</li>
<li>4、已开具发票的订单,若发票未与商品一起寄回,则无法办理退货,换货无需寄回发票</li>
</ul>
<p>若以上内容未解决您的问题,请联系在线客服为您解答。</p>
</section>
</div>
... ...
<div class="deal-main">
<section class="detail">
<h3>7天无理由退货条例总则</h3>
<br>
<h4>订单退换货时效是多久?</h4>
自订单签收次日起7日内可以退货,15日内可以换货(以快递公司的送货单上的签收日期为准)。
<br>
<br>
<h4>出现哪些情形时,消费者可在签收7天内无理由退货</h4>
1.商品客观问题
<br>
2.商品及商品本身包装保持Yoho!BLK出售时原装且配件赠品齐全,不影响二次销售的。
<br>
<br>
<ul>
<li>1.商品客观问题</li>
<li>2.商品及商品本身包装保持Yoho!BLK出售时原装且配件赠品齐全,不影响二次销售的。</li>
</ul>
<h4>哪些商品不支持7天无理由退货</h4>
考虑到个人卫生,内衣,内裤、袜子、泳衣泳裤、贴身塑身衣类商品(具体以网站内商品分类为准),不支持7天无理由退换货,同时,手表、香水、香薰、化妆品等特殊商品,无质量问题不支持7天无理由退换货。
<br>
<br>
<ul>
<li>考虑到个人卫生,内衣,内裤、袜子、泳衣泳裤、贴身塑身衣类商品(具体以网站内商品分类为准),不支持7天无理由退换货,同时,手表、香水、香薰、化妆品等特殊商品,无质量问题不支持7天无理由退换货。</li>
</ul>
<h4>出现哪些情形时不予退货</h4>
1.任何非Yoho!BLK出售的商品(商品编码不符);
<br>
2.已经超过三包期限的商品;
<br>
3.未经授权的维修、误用、碰撞、疏忽、滥用、进液、事故、改动、不正确的安装所造成的商品质量问题,或撕毁、涂改标贴、机器序号、防伪标记;
<br>
4.无法提供商品的发票(如已索要发票)、保修卡等三包凭证或者三包凭证信息与商品不符及被涂改的;
<br>
5.其他依法不应办理退换货的(详见各类商品退货细则)。
  <br>
<br>
<ul>
<li>1.任何非Yoho!BLK出售的商品(商品编码不符);</li>
<li>2.已经超过三包期限的商品;</li>
<li>3.未经授权的维修、误用、碰撞、疏忽、滥用、进液、事故、改动、不正确的安装所造成的商品质量问题,或撕毁、涂改标贴、机器序号、防伪标记;</li>
<li>4.无法提供商品的发票(如已索要发票)、保修卡等三包凭证或者三包凭证信息与商品不符及被涂改的;</li>
<li>5.其他依法不应办理退换货的(详见各类商品退货细则)。</li>
</ul>
<h4>退货运费由谁承担</h4>
1.因商品质量问题产生的退货,退货运费由Yoho!BLK承担,需要您先行垫付,退款后联系客服退运费;
<br>
2.因您个人原因产生的退货,购买时产生的运费及退货运费由您个人承担。
<br>
<br>
<h4>服饰箱包及鞋类商品退货细则</h4>
  <br>
<ul>
<li>1.因商品质量问题产生的退货,退货运费由Yoho!BLK承担,需要您先行垫付,退款后联系客服退运费;</li>
<li>2.因您个人原因产生的退货,购买时产生的运费及退货运费由您个人承担。</li>
</ul>
<h3>服饰箱包及鞋类商品退货细则</h3>
<h4>退换货原因</h4>
1.商品质量问题
<br>
2.商品完好的(即商品及包装保持出售时原状且配件赠品资料齐全的)可以在签收次日起7日内退货,15日内换货
<br>
<br>
<ul>
<li>1.商品质量问题</li>
<li>2.商品完好的(即商品及包装保持出售时原状且配件赠品资料齐全的)可以在签收次日起7日内退货,15日内换货</li>
</ul>
<h4>注意事项</h4>
1.出于安全和卫生考虑,贴身用品如内衣裤、袜子、文胸类及泳衣类等商品,除质量问题外,概不退货;
<br>
2.任何因非正常使用、保管或个人原因造成的商品损坏(如自行修改尺寸,洗涤,皮具表面刮花、打油,刺绣,水洗、碰酸、碱、油或者触硬物,包装盒破损(包括鞋类、礼品类包装盒外直接缠绕胶带或贴快递面单等)雨天穿着,长时间穿着,气味污染等),不予退换。
<br>
3.商品吊牌、发货单、商品配件(如配饰挂坠、肩带、小卡包等)、说明书、保修单、标签等丢失,不予退货;如您购买时索要发票,一经退货请将发票随商品一同寄回,如发票丢失将无法办理退货;
<br>
4.商品及商品本身包装保持Yoho!BLK出售时原状且配件齐全,吊牌包装完整,不影响二次销售,在退换货期限内可以办理退换货;
<br>
5.遇过敏问题产生退换货需要提供医院的相关证明;
<br>
6.礼包或套装中的商品不可以部分退货,如有发票、赠品等需同商品一起退回。
<br>
<br>
<h4>美容化妆类商品退货细则</h4>
  <br>
<ul>
<li>1.出于安全和卫生考虑,贴身用品如内衣裤、袜子、文胸类及泳衣类等商品,除质量问题外,概不退货;</li>
<li>2.任何因非正常使用、保管或个人原因造成的商品损坏(如自行修改尺寸,洗涤,皮具表面刮花、打油,刺绣,水洗、碰酸、碱、油或者触硬物,包装盒破损(包括鞋类、礼品类包装盒外直接缠绕胶带或贴快递面单等)雨天穿着,长时间穿着,气味污染等),不予退换。</li>
<li>3.商品吊牌、发货单、商品配件(如配饰挂坠、肩带、小卡包等)、说明书、保修单、标签等丢失,不予退货;如您购买时索要发票,一经退货请将发票随商品一同寄回,如发票丢失将无法办理退货;</li>
<li>4.商品及商品本身包装保持Yoho!BLK出售时原状且配件齐全,吊牌包装完整,不影响二次销售,在退换货期限内可以办理退换货;</li>
<li>5.遇过敏问题产生退换货需要提供医院的相关证明;</li>
<li>6.礼包或套装中的商品不可以部分退货,如有发票、赠品等需同商品一起退回。</li>
</ul>
<h3>美容化妆类商品退货细则</h3>
<h4>退货原因</h4>
商品质量问题。
<br>
<br>
<ul>
<li>商品质量问题。</li>
</ul>
<h4>注意事项</h4>
1.出于安全和卫生考虑,已使用的美容化妆品不予退货,经权威部门检测商品存在内在质量问题者除外。
<br>
2.如商品包装破损,商品过期可以申请质量问题退换货;
<br>
3.商品销售页面明确标示商品保质期将到期、外包装有损坏或产品有瑕疵的,不得再以此为由要求退换货。
<br>
4.遇过敏问题产生退货需要提供医院的相关证明。
<br>
5.Yoho!BLK保证商品的进货渠道和质量,如果您在使用时对商品质量表示质疑,请出具书面鉴定,有货会按照国家法律规定予以处理。
<br>
<span style="color:#ff0000;">温馨提醒:</span>化妆品的使用效果会因肤质、年龄、季节、气候、使用方法以及配套产品等的不同而效果不一,因此,介绍的功能及使用效果仅供参考,如果您对商品细节有任何疑问,请在订购前与客服联系并详细确认。
  <br>
<br>
<h4>家居家纺类商品退货细则</h4>
<br>
<ul>
<li>1.出于安全和卫生考虑,已使用的美容化妆品不予退货,经权威部门检测商品存在内在质量问题者除外。</li>
<li>2.如商品包装破损,商品过期可以申请质量问题退换货;</li>
<li>3.商品销售页面明确标示商品保质期将到期、外包装有损坏或产品有瑕疵的,不得再以此为由要求退换货。</li>
<li>4.遇过敏问题产生退货需要提供医院的相关证明。</li>
<li>5.Yoho!BLK保证商品的进货渠道和质量,如果您在使用时对商品质量表示质疑,请出具书面鉴定,有货会按照国家法律规定予以处理。</li>
<li><span style="color:#ff0000;">温馨提醒:</span>化妆品的使用效果会因肤质、年龄、季节、气候、使用方法以及配套产品等的不同而效果不一,因此,介绍的功能及使用效果仅供参考,如果您对商品细节有任何疑问,请在订购前与客服联系并详细确认。</li>
</ul>
<h3>家居家纺类商品退货细则</h3>
<h4>退货原因</h4>
1.商品质量问题;
<br>
2.商品及商品本身包装保持Yoho!BLK出售时原装且配件齐全,不影响二次销售的,在订单签收次日起7日内可退货,15日内可换货。
  <br>
<br>
<ul>
<li>1.商品质量问题;</li>
<li>2.商品及商品本身包装保持Yoho!BLK出售时原装且配件齐全,不影响二次销售的,在订单签收次日起7日内可退货,15日内可换货。</li>
</ul>
<h4>注意事项</h4>
1.因个人原因造成商品损坏(如自行修改尺寸、洗涤)的,不予退货;
<br>
2.商品吊牌、发货单、商品配件、说明书、保修单及标签等丢失的或包装破损,不予退货。
<br>
<br>
<ul>
<li>1.因个人原因造成商品损坏(如自行修改尺寸、洗涤)的,不予退货;</li>
<li>2.商品吊牌、发货单、商品配件、说明书、保修单及标签等丢失的或包装破损,不予退货。</li>
</ul>
<h4>手表类商品退换货细则</h4>
手表类商品不支持7天无理由退换货,感谢您的理解与支持!
<br>
<br>
<ul>
<li>手表类商品不支持7天无理由退换货,感谢您的理解与支持!</li>
</ul>
<h4>注意事项</h4>
1.请您务必将商品的外包装、内带附件、保修卡、说明书等随同商品一起寄回。
<br>
2.如超过退换货时间,购买的商品出现质量问题,请您与Yoho!BLK客服中心联系,我们会帮您联系维修点或者返厂维修,若二次维修仍然存在问题,我们会帮您办理退换。
<br>
<br>
<ul>
<li>1.请您务必将商品的外包装、内带附件、保修卡、说明书等随同商品一起寄回。</li>
<li> 2.如超过退换货时间,购买的商品出现质量问题,请您与Yoho!BLK客服中心联系,我们会帮您联系维修点或者返厂维修,若二次维修仍然存在问题,我们会帮您办理退换。</li>
</ul>
<h4>珠宝类商品退换货细则</h4>
珠宝类商品不支持7天无理由退换货,感谢您的理解与支持!
<ul>
<li>珠宝类商品不支持7天无理由退换货,感谢您的理解与支持!</li>
</ul>
</section>
</div>
... ...
<div class="deal-main">
<section class="detail">
<h4>支付说明</h4>
1、Yoho!BLK为您提供支付宝进行在线支付,APP另可通过微信支付进行在线支付;
<br>
2、如果您的Yoho!Family账户内有有货币,您可以在结算时选择使用;
<br>
3、网上支付均是支付成功即刻到账。若由于网络故障导致您已支付成功的订单未改变订单状态,请您联系我们的客服专员为您解决。
<br>
<span style="color:#ff0000;">温馨提醒:</span>在线支付付款等待期限为2小时。请您在订购成功后2小时内完成支付,否则我们将不会保留您的订单。
<br>
<br>
<ul>
<li>1、Yoho!BLK为您提供支付宝进行在线支付,APP另可通过微信支付进行在线支付;</li>
<li>2、如果您的Yoho!Family账户内有有货币,您可以在结算时选择使用;</li>
<li>3、网上支付均是支付成功即刻到账。若由于网络故障导致您已支付成功的订单未改变订单状态,请您联系我们的客服专员为您解决。</li>
<li><span style="color:#ff0000;">温馨提醒:</span>在线支付付款等待期限为2小时。请您在订购成功后2小时内完成支付,否则我们将不会保留您的订单。</li>
</ul>
<h4>发票说明</h4>
1、如果您需要发票,请您在结算商品时勾选发票,商品将连同发票一并寄出;
<br>
2、发票金额根据您的订单实付金额开具;
<br>
3、若您收到包裹后确认未收到发,请您及时与客服联系处理。
<br>
<br>
<ul>
<li>1、如果您需要发票,请您在结算商品时勾选发票,商品将连同发票一并寄出;</li>
<li>2、发票金额根据您的订单实付金额开具;</li>
<li>3、若您收到包裹后确认未收到发,请您及时与客服联系处理。</li>
</ul>
<h4>Yoho!BLK是否提供增值专用税发票?</h4>
目前,Yoho!BLK可以提供增值税专用发票。
<br>
注明:开具增值税专用发票需要提供:名称、纳税人识别号、地址、电话、开户行、帐号以及发票类型。
<br>
<br>
<ul>
<li>目前,Yoho!BLK可以提供增值税专用发票。</li>
<li>注明:开具增值税专用发票需要提供:名称、纳税人识别号、地址、电话、开户行、帐号以及发票类型。</li>
</ul>
<h4>增值税普通发票与增值税专业发票有什么区别?</h4>
重点区别在于“能否抵扣增值税销项税”方面:
<br>
1、企业采购货货物收到供应方的“增值税普通发票”,其支付款中所含的“进项税”记入货物成本,不能抵扣企业因销售等业务活动产生的增值税销项税,实现不了增值税的流转;
<br>
2、企业采购货货物收到供应方的“增值税专用发票”其进项税,可以在规定范围内抵扣企业销售等业务活动产生的销项税,从而实现增值税的流转。
  <br>
<br>
<p>重点区别在于“能否抵扣增值税销项税”方面:</p>
<ul>
<li>1、企业采购货货物收到供应方的“增值税普通发票”,其支付款中所含的“进项税”记入货物成本,不能抵扣企业因销售等业务活动产生的增值税销项税,实现不了增值税的流转;</li>
<li>2、企业采购货货物收到供应方的“增值税专用发票”其进项税,可以在规定范围内抵扣企业销售等业务活动产生的销项税,从而实现增值税的流转。</li>
</ul>
<h4>购买商品的时候忘记勾选发票了,可以补寄吗?</h4>
1) 发票可以补100天之内订购的订单。
<br>
2) 补开发票需提供“Yoho!BLK发货单”或详细的订购信息。
<br>
3) 补开发票所产成的运费由Yoho!BLK承担。
<br>
<br>
<ul>
<li>1) 发票可以补100天之内订购的订单。</li>
<li>2) 补开发票需提供“Yoho!BLK发货单”或详细的订购信息。</li>
<li>3) 补开发票所产成的运费由Yoho!BLK承担。</li>
</ul>
<h4>如何更换发票?</h4>
您在收到发票后如果发现因商家原因所致票据抬头、内容或金额错误,请联系客服专员为您安排办理换发票事宜,往返快递费用由责任方承担。
<br>
<br>
若以上内容未解决您的问题,请联系在线客服为您解答。
<ul>
<li>您在收到发票后如果发现因商家原因所致票据抬头、内容或金额错误,请联系客服专员为您安排办理换发票事宜,往返快递费用由责任方承担。</li>
</ul>
<p>若以上内容未解决您的问题,请联系在线客服为您解答。</p>
</section>
</div>
... ...
... ... @@ -39,7 +39,7 @@ module.exports = {
sort: req.query.sort,
page: req.query.page,
channel: req.query.channel || 'men',
gender: req.query.gender || '1,2,3',
gender: '1,2,3', // 店铺 不分 性别
brand: req.query.brand,
shopId: req.query.id,
order: req.query.order || 's_t_desc',
... ...
... ... @@ -23,7 +23,7 @@ module.exports = {
api: 'http://dev-api.yohops.com:9999/',
service: 'http://dev-service.yohops.com:9999/',
singleApi: 'http://192.168.102.31:8092/'
singleApi: 'http://192.168.102.27:8092/'
},
subDomains: {
host: '.m.yohoblk.com',
... ... @@ -119,7 +119,7 @@ if (isProduction) {
api: 'http://api-test1.yohops.com:9999/',
service: 'http://service-test1.yohops.com:9999/',
singleApi: 'http://192.168.102.31:8092/'
singleApi: 'http://192.168.102.27:8092/'
},
memcache: {
master: ['127.0.0.1:12111'],
... ...
... ... @@ -28,7 +28,7 @@
"express-handlebars": "^3.0.0",
"express-session": "^1.14.0",
"influxdb-winston": "^1.0.1",
"lodash": "^4.14.2",
"lodash": "^4.15.0",
"memcached": "^2.2.1",
"moment": "^2.14.1",
"morgan": "^1.7.0",
... ... @@ -39,7 +39,7 @@
"winston": "^2.2.0",
"winston-daily-rotate-file": "^1.1.4",
"yoho-md5": "^2.0.0",
"yoho-node-lib": "0.0.38"
"yoho-node-lib": "0.0.40"
},
"devDependencies": {
"autoprefixer": "^6.4.0",
... ... @@ -48,7 +48,7 @@
"babel-plugin-transform-runtime": "^6.12.0",
"babel-preset-es2015": "^6.13.2",
"babel-runtime": "^6.11.6",
"eslint": "^3.2.2",
"eslint": "^3.3.1",
"eslint-config-yoho": "^1.0.1",
"eslint-plugin-html": "^1.5.2",
"extract-text-webpack-plugin": "^1.0.1",
... ... @@ -82,14 +82,16 @@
"stylelint-processor-html": "^1.0.0",
"vue": "1.0.26",
"vue-infinite-scroll": "0.2.3",
"vue-lazyload": "^0.4.5",
"vue-lazyload": "0.4.5",
"vue-loader": "^8.5.3",
"vue-swipe": "0.2.6",
"vue-touch": "1.1.0",
"webpack": "^1.13.1",
"webpack-dashboard": "0.0.1",
"webpack-dev-server": "^1.14.1",
"webpack-stream": "^3.1.0",
"yoho-cookie": "1.2.0",
"yoho-qs": "1.0.1"
"yoho-qs": "1.0.1",
"yoho-store": "^1.3.20"
}
}
... ...
... ... @@ -18,6 +18,8 @@ const webpack = require('webpack');
const WebpackDevServer = require('webpack-dev-server');
const webpackConfig = require('./webpack.config.js');
const ExtractTextPlugin = require('extract-text-webpack-plugin');
const Dashboard = require('webpack-dashboard');
const DashboardPlugin = require('webpack-dashboard/plugin');
const env = {
dev: Symbol('development'),
... ... @@ -184,6 +186,7 @@ gulp.task('postcss', ['assets'], () => {
// webpack dev server
gulp.task('webpack-dev-server', () => {
const useDashboard = process.platform === 'darwin' || process.platform === 'linux';
const devConfig = Object.assign({}, webpackConfig, {
devtool: '#inline-source-map',
vue: {
... ... @@ -200,10 +203,25 @@ gulp.task('webpack-dev-server', () => {
}
});
devConfig.output.publicPath = 'http://localhost:5004/';
// 开发环境插件
devConfig.plugins.push(new webpack.HotModuleReplacementPlugin());
if (useDashboard) {
const dashboard = new Dashboard(); // webpackDashboardPlugin
devConfig.plugins.push(new DashboardPlugin(dashboard.setData));
}
devConfig.entry.libs.unshift(`webpack-dev-server/client?${devConfig.output.publicPath}`, 'webpack/hot/dev-server');
new WebpackDevServer(webpack(devConfig), {
contentBase: '.',
publicPath: '//localhost:5004/',
publicPath: devConfig.output.publicPath,
hot: true,
inline: true,
quiet: useDashboard,
stats: {
colors: true
},
... ... @@ -214,7 +232,7 @@ gulp.task('webpack-dev-server', () => {
if (err) {
throw new gutil.PluginError('webpack-dev-server', err);
}
gutil.log('[webpack-serve]', 'http://localhost:5004/');
gutil.log('[webpack-serve]', devConfig.output.publicPath);
});
});
... ... @@ -223,7 +241,7 @@ gulp.task('webpack', ['assets'], (done) => {
const proConfig = Object.assign({}, webpackConfig, {
vue: {
postcss: {
plugins: postcssPlugin(env.dev),
plugins: postcssPlugin(env.pro),
options: {
parser: require('postcss-scss')
}
... ...
<div class="modal {{styleClass}}">
<h2>{{title}}</h2>
<p>{{text}}</p>
<p>{{{text}}}</p>
<hr>
<div class="button-group">
{{#each buttons}}
... ...
... ... @@ -2,7 +2,6 @@
* 拦截跳转, 在这里给将要打开的页面设置一下 header 样式
* @return {[type]}
*/
const $ = require('jquery');
const yoho = require('yoho');
const parse = require('yoho-qs/parse'); // 提供解析函数
... ... @@ -158,7 +157,7 @@ const matchHeader = (path, qs, titleMap) => {
if (/\/me\/logistic$/.test(path)) {
header = titleMap[1];
header.title.des = '物流详情';
header.title.des = '物流信息';
return header;
}
... ... @@ -232,7 +231,7 @@ const matchHeader = (path, qs, titleMap) => {
const intercept = (url) => {
if (yoho.isApp) {
let titleMap = $.extend({}, defaultTitleMap);
let titleMap = Object.assign({}, defaultTitleMap);
let [path, qs] = url.split('?');
qs = parse(qs);
... ... @@ -243,6 +242,8 @@ const intercept = (url) => {
if (qs.tab === 'brand') {
header.defaultSelectedIndex = '1';
} else {
header.defaultSelectedIndex = '0';
}
return yoho.goPageView({
header: header
... ...
... ... @@ -81,7 +81,7 @@ class Modal {
}
}
$.extend(Modal, {
Object.assign(Modal, {
alert: (text, title)=> {
const modal = new Modal({
text: text,
... ...
... ... @@ -52,14 +52,14 @@ class Overlay {
}
});
if (this.settings.disableScrolling) {
// 覆盖层出现时阻止滚动
$(window).on('touchmove', (e)=> {
if (this.isVisible) {
e.preventDefault();
}
});
}
// if (this.settings.disableScrolling) {
// // 覆盖层出现时阻止滚动
// $(window).on('touchmove', (e)=> {
// if (this.isVisible) {
// e.preventDefault();
// }
// });
// }
this.elem[0].addEventListener('webkitTransitionEnd', this._cleanup.bind(this));
}
... ...
... ... @@ -23,11 +23,11 @@ function tip(param) {
};
if (typeof param === 'string') {
$.extend(viewData, {
Object.assign(viewData, {
txt: param
});
} else {
$.extend(viewData, param);
Object.assign(viewData, param);
}
const tipView = `<div class="tip-box"><div class="tip">${viewData.txt}</div></div>`;
... ...
... ... @@ -12,6 +12,7 @@
* 这一块的代码很少
*
* 1. cookie 操作请使用 yoho-cookie 文档:https://github.com/florian/cookie.js
* 1. localStorage 操作请使用 yoho-store 文档:https://github.com/marcuswestin/store.js
* 2. 查询字符串读取 请使用 yoho-qs
*/
const $ = require('jquery');
... ...
... ... @@ -3,7 +3,7 @@ var $ = require('jquery');
var interceptClick = require('common/intercept-click');
$(() => {
const header = $.extend({}, interceptClick.defaultTitleMap[1]);
const header = Object.assign({}, interceptClick.defaultTitleMap[1]);
header.title.des = '关于';
yoho.updateNavigationBar({
... ...
... ... @@ -2,15 +2,18 @@ const Vue = require('vue');
const infiniteScroll = require('vue-infinite-scroll');
const favBrandList = require('me/fav-brand-list.vue');
const VueTouch = require('vue-touch');
const yoho = require('yoho');
require('common/vue-filter')(Vue);
Vue.use(VueTouch);
Vue.use(infiniteScroll);
new Vue({
el: '#fav-content',
components: {
favBrandList
}
});
yoho.ready(() => {
new Vue({
el: '#fav-content',
components: {
favBrandList
}
});
})
... ...
... ... @@ -2,15 +2,18 @@ const Vue = require('vue');
const infiniteScroll = require('vue-infinite-scroll');
const favProductList = require('me/fav-product-list.vue');
const VueTouch = require('vue-touch');
const yoho = require('yoho');
require('common/vue-filter')(Vue);
Vue.use(VueTouch);
Vue.use(infiniteScroll);
new Vue({
el: '#fav-content',
components: {
favProductList
}
yoho.ready(() => {
new Vue({
el: '#fav-content',
components: {
favProductList
}
});
});
... ...
... ... @@ -41,7 +41,7 @@ $(() => {
});
});
const header = $.extend({}, interceptClick.defaultTitleMap[3]);
const header = Object.assign({}, interceptClick.defaultTitleMap[3]);
header.title.des = '意见反馈';
header.right = {
... ...
var yoho = require('yoho');
var $ = require('jquery');
var util = require('common/util');
const Vue = require('vue');
const home = require('me/home.vue');
const yoho = require('yoho');
yoho.ready(() => {
if (!yoho.isLogin) {
$('.auth').addClass('no-intercept');
$('.auth').on('click', function() {
yoho.goLogin();
return false;
});
} else {
// 地址管理
$('#address').on('click', function() {
yoho.goAddress({
type: '2'
});
return false;
});
}
// 系统设置
$('#setting').on('click', function() {
yoho.goSetting();
return false;
});
yoho.showLoading(false);
window.addEventListener('touchmove', function() {
var topHeight = document.body.scrollTop;
if (topHeight > 50) {
$('#header').addClass('top-change');
} else {
$('#header').removeClass('top-change');
}
});
document.addEventListener('visibilitychange', () => {
if (!document.hidden) {
location.reload();
new Vue({
el: '#home',
components: {
home
}
});
});
... ...
const Vue = require('vue');
const orderLogistic = require('me/order-logistic.vue');
require('common/vue-filter')(Vue);
new Vue({
el: '#order-logistic',
data: {
... ...
const $ = require('jquery');
const yoho = require('yoho');
const interceptClick = require('common/intercept-click');
const Modal = require('common/modal');
... ... @@ -19,7 +18,7 @@ exports.applySuccuss = function(type, applyId) {
let kind = config[type];
let goStatusPage = function() {
let header = $.extend({}, interceptClick.defaultTitleMap[1]);
let header = Object.assign({}, interceptClick.defaultTitleMap[1]);
header.left.action = location.origin + '/me/return';
header.title.des = `${kind.name}状态`;
... ...
... ... @@ -9,6 +9,7 @@
* 希望能与 微信 JS-SDK 一样方便
*/
const cookie = require('yoho-cookie');
const store = require('yoho-store');
const tip = require('common/tip');
/* 空方法 */
... ... @@ -24,20 +25,27 @@ const yoho = {
isApp: /yh_blk/i.test(navigator.userAgent || ''),
/**
* 判断是否是 登录
* store
*/
isLogin: cookie.get('_YOHOUID'),
store: store,
/**
* JS 与 APP 共享的对象
*/
data: window.yohoInterfaceData,
/**
* 判断是否是 登录
*/
isLogin() {
return cookie.get('_YOHOUID');
},
ready(callback) {
if (this.isApp) {
document.addEventListener('deviceready', callback);
} else {
callback();
return callback();
}
},
... ... @@ -170,11 +178,7 @@ const yoho = {
* @param fail 调用失败的回调方法
*/
goNewPage(args, success, fail) {
if (this.isApp) {
if (!window.yohoInterface) {
return false;
}
if (this.isApp && window.yohoInterface) {
window.yohoInterface.triggerEvent(success || nullFun, fail || nullFun, {
method: 'go.newPage',
arguments: args
... ... @@ -318,7 +322,8 @@ const yoho = {
arguments: args
});
} else {
tip(tipInfo);
// tip(tipInfo);
}
},
... ...
... ... @@ -51,6 +51,5 @@
p {
text-align: center;
font-size: 24px;
font-family: BrownStd Regular;
}
}
... ...
... ... @@ -3,12 +3,15 @@
padding-top: 20px;
.coin-total {
padding: 35px 0;
padding: 40px 0;
background: white;
text-align: center;
border-top: 1px solid #eee;
border-bottom: 1px solid #eee;
p:first-child {
font-size: 34px;
line-height: 40px;
}
p:nth-child(2) {
... ... @@ -20,6 +23,7 @@
p:last-child {
color: #b0b0b0;
font-size: 28px;
line-height: 40px;
}
}
... ...
... ... @@ -2,7 +2,6 @@
width: 100%;
height: auto;
overflow: hidden;
margin-top: 20px;
background-color: #fff;
ul {
... ... @@ -52,7 +51,6 @@
> label {
width: 100%;
height: 100%;
line-height: 80px;
font-size: 34px;
margin-right: 8%;
... ... @@ -60,6 +58,7 @@
white-space: nowrap;
overflow: hidden;
display: inline-block;
vertical-align: middle;
.nickname {
text-align: right;
... ...
... ... @@ -15,16 +15,16 @@
width: 100%;
max-width: 100%;
min-width: 100%;
height: 420px;
max-height: 255px;
height: 419px;
min-height: 255px;
padding: 30px;
font-size: 30px;
line-height: 48px;
font-size: 28px;
line-height: 40px;
color: #000;
display: block;
background: #fff;
border: none;
border-bottom: solid 1px #eee;
outline: none;
resize: none;
}
... ...
.help {
overflow: hidden;
width: 100%;
height: auto;
margin-top: 20px;
ul {
/* 全部重写 */
ul li {
display: block;
position: relative;
padding: 0 30px;
font-size: 34px;
line-height: 88px;
overflow: hidden;
margin: 0;
padding-left: 0;
width: 100%;
height: auto;
li {
float: right;
overflow: hidden;
width: 100%;
height: 80px;
border-bottom: 1px solid #e0e0e0;
color: #444;
list-style: none;
font-size: 28px;
line-height: 84px;
a:visited {
color: #444;
}
.name {
float: left;
overflow: hidden;
padding-left: 5%;
width: 90%;
height: 100%;
}
a {
display: block;
border-bottom: 1px solid #eee;
}
.icon {
color: #e0e0e0;
}
.icon {
color: #b0b0b0;
line-height: 88px;
}
}
.iconfont {
color: #fff;
.icon-right {
float: right;
}
}
}
.help-detail-page {
margin-right: 30px;
margin-left: 30px;
.deal-main {
.detail {
h4 {
line-height: 60px;
}
ul {
margin-bottom: 15px;
}
p {
line-height: 40px;
margin-top: 40px;
}
}
}
... ...
.my-page {
color: #444;
background: #f0f0f0;
a {
color: #000;
}
.blk-header {
box-sizing: content-box;
position: fixed;
top: 0;
right: 0;
left: 0;
z-index: 210;
padding: 20px 30px;
height: 70px;
max-width: 750px;
margin-left: auto;
margin-right: auto;
line-height: 70px;
font-size: 48px;
background-color: #fff;
border-bottom: 1px solid #eee;
color: #000;
.icon {
vertical-align: middle;
}
}
.top-box {
.blk-header {
background-color: transparent;
border-bottom: 0;
}
}
.top-change {
.blk-header {
background-color: #fff;
}
}
.blk-header-left {
float: left;
}
.blk-header-gap {
height: calc(70 + 20 * 2 + 1)px;
background-color: transparent;
}
.my-header {
height: 469px;
background: resolve("me/header-bg.png");
background-size: cover;
}
.user-info {
display: block;
position: relative;
top: 145px;
padding: 0 30px;
margin: 0 180px;
color: #000;
font-size: 34px;
text-align: center;
.user-avatar {
display: inline-block;
position: relative;
width: 174px;
height: 174px;
border-radius: 50%;
margin: 0 auto;
border: 3px solid #b0b0b0;
background: resolve("me/user-icon.png");
background-size: 100%;
}
}
.username {
display: block;
text-align: center;
text-overflow: ellipsis;
white-space: nowrap;
font-size: 32px;
position: relative;
top: 140px;
}
.my-order {
margin-bottom: 20px;
border-top: 1px solid #eee;
border-bottom: 1px solid #eee;
background: #fff;
.order-title {
display: block;
padding: 0 30px;
font-size: 34px;
line-height: 88px;
&.highlight {
background: #eee;
}
.read-order {
color: #b0b0b0;
font-size: 30px;
float: right;
}
}
.order-type {
padding: 20px 0;
text-align: center;
border-top: 1px solid #eee;
.icon {
font-size: 45px;
}
.type-item {
position: relative;
float: left;
color: #444;
font-size: 24px;
line-height: 1.5;
width: 75px;
margin-left: 130px;
&.highlight {
background: #eee;
}
&:first-child {
margin-left: 34px;
}
.num {
position: absolute;
top: -35px;
right: -20px;
width: 72px;
height: 72px;
font-size: 34px;
line-height: 72px;
color: #fff;
background: #f03d35;
text-align: center;
border-radius: 50%;
transform: scale(0.5);
}
}
}
}
.group-list {
margin-bottom: 20px;
border-top: 1px solid #eee;
border-bottom: 1px solid #eee;
background: #fff;
.glist-item {
display: block;
position: relative;
padding: 0 30px;
font-size: 34px;
line-height: 88px;
overflow: hidden;
&.highlight {
background: #eee;
}
&:after {
content: "";
position: absolute;
right: 0;
bottom: 0;
width: 100%;
height: 0;
border-top: 1px solid #eee;
}
&:last-child:after {
content: none;
}
}
.icon {
font-size: 34px;
vertical-align: top;
}
.num {
color: #b0b0b0;
float: right;
}
}
}
.app.ios {
.blk-header {
padding-top: 80px;
}
}
@import "home";
@import "help";
@import "helpdetail";
@import "feedback";
... ...
... ... @@ -7,7 +7,6 @@
.edit-logistics {
display: inline-block;
margin-top: 20px;
padding: 0 30px;
width: 100%;
background: #fff;
... ...
... ... @@ -166,6 +166,14 @@ body {
font-size: 30px;
color: #b0b0b0;
}
.goods-status {
background-color: #4A90E2;
color: #fffefe;
font-size: 22px;
border-radius: 15px;
padding: 5px 10px;
}
}
}
... ...
... ... @@ -97,7 +97,7 @@ $white: #fff;
.goods-detail {
flex: 1;
margin: 0 20px;
margin: 0 24px;
font-size: 24px;
span {
... ... @@ -118,6 +118,7 @@ $white: #fff;
.size {
color: #b0b0b0;
margin: 20px 0;
}
}
... ... @@ -129,7 +130,7 @@ $white: #fff;
}
p:last-of-type {
font-size: 30px;
font-size: 20px;
color: #b0b0b0;
}
}
... ...
... ... @@ -19,9 +19,13 @@
<style>
.brand-list-box {
width: 100%;
padding: 0 30px;
padding: 30px 0;
background: #f6f6f6;
.per-brand-box {
background: #fff;
padding: 0 30px;
.index {
padding: 18px 0;
... ...
<template>
<div class="search">
<div v-else class="input" @click='yoho.goSearch()'>
<span class="icon icon-search"></span> Search
<span class="icon icon-search"></span><span class="search-text">Search</span>
</div>
</div>
</template>
... ... @@ -9,7 +9,7 @@
.search {
width: 100%;
height: 85px;
padding: 15px 0;
padding: 15px 16px;
background-color: #f6f6f6;
text-align: center;
... ... @@ -20,12 +20,14 @@
text-align: center;
color: #b0b0b0;
height: 56px;
width: 92%;
font-size: 28px;
padding: 5px 0;
border-radius: 8px;
}
.search-text {
margin-left: 16px;
}
}
}
</style>
<script>
... ...
... ... @@ -72,6 +72,7 @@
content: "";
position: absolute;
left: 30px;
bottom: 0;
width: 100%;
height: 0;
border-bottom: 1px solid #eee;
... ...
<template>
<div class="blk-header-wrap" :class="class">
<div class="blk-header-wrap" :class="[class, {'is-fixed': fixed}]">
<div class="blk-header">
<div class="blk-header-left">
<slot name="left">
... ... @@ -13,14 +13,19 @@
<span class="blk-header-title">{{title}}</span>
</div>
</div>
<div class="blk-header-gap"></div>
<div class="blk-header-gap" v-if="!fixed"></div>
</div>
</template>
<script>
const yoho = require('yoho');
module.exports = {
props: ['title', 'class'],
props: {
'title': String,
'class': [String, Object, Array],
'fixed': Boolean,
'scrollFix': Boolean
},
methods: {
goBack() {
yoho.goBack({}, function() {}, function() {});
... ... @@ -35,6 +40,10 @@
transition: 0.3s all;
border-bottom: 0;
}
.blk-header-title {
visibility: hidden;
}
}
.blk-header {
box-sizing: content-box;
... ...
... ... @@ -134,7 +134,6 @@
const self = this;
this.overlay = new Overlay({
disableScrolling: true,
onClose: function() {
self.isVisible = false;
}
... ... @@ -156,7 +155,7 @@
top: 0;
right: 0;
bottom: 0;
left: 150px;
width: 530px;
background-color: #fff;
transform: translate3d(100%, 0, 0);
transition: all 0.3s 0.2s;
... ... @@ -208,7 +207,7 @@
.filter-cate-val {
float: right;
font-size: 28px;
max-width: 45%;
max-width: 33%%;
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
... ...
... ... @@ -39,7 +39,6 @@
}
res[groupName].push(brand);
});
console.log(res);
return res;
}
}
... ...
... ... @@ -30,7 +30,6 @@
return true;
},
hide() {
console.log('hide');
this.isVisible = false;
}
}
... ...
... ... @@ -51,7 +51,8 @@
.swipe-indicators {
left: initial;
right: -30px;
right: 30px;
transform: none;
}
.swipe-indicator {
... ...
... ... @@ -26,7 +26,7 @@
<h2 class="editorial-relate-title">相关品牌</h2>
<ul>
<li v-for="item in brands">
<a :href="item.brandDomain | brandUrl"><img :src="item.thumb"></a>
<a :href="item.url | brandUrl"><img :src="item.thumb"></a>
</li>
</ul>
</div>
... ... @@ -204,7 +204,6 @@
const editorialId = $('#app').data('editorialId');
this.id = editorialId;
let loadDeferred = null;
$.get(`/editorial/editorial_${editorialId}.json`).then(result => {
const article = result[0],
... ... @@ -212,7 +211,7 @@
brands = result[2],
other = result[3];
let goods, prodMap = {};
let goods = {};
if (article && article.code === 200 && article.data) {
this.article = article.data;
... ... @@ -237,27 +236,19 @@
}
// 延时读取商品价格、名称等信息
loadDeferred = () => {
if (!goods || !goods.length) {
return;
}
$.get('/product/search_product.json', {
ids: goods.map((item)=> {
return item.id;
}).join(',')
}).then((data)=> {
if (data.data) {
this.$set('recommendProducts', data.data.productList);
}
});
};
});
$(window).on('scroll', ()=> {
if ($(window).scrollTop() > 100 && loadDeferred) {
loadDeferred();
loadDeferred = null;
if (!goods || !goods.length) {
return;
}
$.get('/product/search_product.json', {
ids: goods.map((item)=> {
return item.id;
}).join(',')
}).then((data) => {
if (data.data) {
this.$set('recommendProducts', data.data.productList);
}
});
});
}
};
... ...
... ... @@ -19,10 +19,12 @@
</div>
</div>
</div>
<div v-if="!scrollDisabled" class="is-loading">loading...</div>
</template>
<style>
.editorial-box {
background: #f6f6f6;
border-bottom: #eee 1px solid;
.img {
width: 100%;
... ... @@ -38,35 +40,49 @@
.title {
background: #fff;
font-size: 42px;
line-height: 46px;
line-height: 43px;
font-weight: 700;
padding: 10px 20px;
padding: 30px;
}
.editorial-des {
background: #fff;
padding: 10px 20px;
padding: 0 30px 30px;
color: #b0b0b0;
font-size: 28px;
line-height: 32px;
}
hr {
margin: 0 20px;
margin: 0 30px;
border: #eee 1px solid;
border-bottom: 0;
}
.bottom {
padding: 10px 20px;
padding: 10px 30px;
background: #fff;
color: #b0b0b0;
font-size: 24px;
height: 78px;
span {
display: inline-block;
padding: 12px 0;
}
.share {
float: right;
padding-top: 16px;
}
}
}
.is-loading {
font-size: 32px;
text-align: center;
padding: 16px 0;
}
</style>
<script>
const util = require('common/util');
... ... @@ -107,7 +123,7 @@
channel: this.channel
}
}).done(result => {
if (result.code === 200) {
if (result.code === 200 && result.data.list.length > 0) {
if (this.editorialList.length > 0 && result.data.list.length > 0) {
this.$set('editorialList', this.editorialList.concat(result.data.list));
} else if (result.data.list.length > 0) {
... ... @@ -129,7 +145,7 @@
/* 分享资讯 */
share(title, des, img, id) {
title = title.length > 15 ? title.substr(0,15)+'...' : title;
title = title.length > 15 ? title.substr(0, 15) + '...' : title;
img = util.getImgUrl(img, 300, 300, 2);
yoho.goShare({
title: title,
... ...
... ... @@ -4,12 +4,12 @@
<template slot="right">
<a class="right-button no-intercept" href="javascript:void(0);" @click="like()">
<span class="icon icon-like" :class=""></span>
{{likeCount}}
</a>
<a class="right-button no-intercept" href="javascript:void(0);" @click="favorite()">
<span class="icon" :class="{ 'icon-love': !isFavorite, 'icon-love-solid': isFavorite}"></span>
{{likeCount ? likeCount : ''}}
</a>
<!--暂时隐藏收藏入口,下个版本使用-->
<!--<a class="right-button no-intercept" href="javascript:void(0);" @click="favorite()">-->
<!--<span class="icon" :class="{ 'icon-love': !isFavorite, 'icon-love-solid': isFavorite}"></span>-->
<!--</a>-->
<a class="right-button no-intercept" href="javascript:void(0);" @click="share()">
<span class="icon icon-share"></span>
... ... @@ -21,7 +21,7 @@
<style>
.top-nav {
.right-button {
margin-left: 30px;
/*margin-left: 30px;*/
}
}
</style>
... ... @@ -65,6 +65,9 @@
if (misc && misc.code === 200) {
this.isLiked = misc.data.isPraise === 'Y';
if (misc.data.isPraise === 'Y') {
tip('点赞成功');
}
}
});
},
... ... @@ -77,7 +80,6 @@
if (result && result.code === 403) {
// 未登录
yoho.goLogin('', () => {
console.log(this);
this.favorite();
}, function() {
tip('登录失败');
... ... @@ -87,12 +89,18 @@
if (misc && misc.code === 200) {
this.isFavorite = misc.data.isFavor === 'Y';
if (misc.data.isFavor === 'Y') {
tip('收藏成功');
} else {
tip('取消收藏');
}
}
});
},
share: function() {
let title = this.article.articleTitle;
title = title.length > 15 ? title.substr(0,15)+'...' : title;
title = title.length > 15 ? title.substr(0, 15) + '...' : title;
yoho.goShare({
title,
... ...
... ... @@ -10,8 +10,6 @@
<script>
var s = 1; // 测试代码检查
console.log(1);
module.exports = {
data() {
return {
... ...
<template>
<div class="coin-detail">
<div class="coin-detail" v-if="coinList && coinList.length">
<p>明细列表</p>
<ul class="coin-detail-list" v-infinite-scroll="getCoinData()" infinite-scroll-disabled="busy" infinite-scroll-distance="10">
<li v-for="coin in coinList">
... ... @@ -35,8 +35,6 @@
methods: {
getCoinData() {
let _that = this;
this.busy = true;
if (this.page >= this.pageTotal) {
return;
... ... @@ -49,10 +47,10 @@
}
}).then(result => {
if (result.code === 200) {
_that.busy = false;
this.busy = false;
if (result.data.coinlist.length > 0) {
this.$set('coinList', _that.coinList.concat(result.data.coinlist));
_that.pageTotal = result.data.pageTotal;
this.$set('coinList', this.coinList.concat(result.data.coinlist));
this.pageTotal = result.data.pageTotal;
}
}
}).fail(() => {
... ...
... ... @@ -123,7 +123,8 @@
const self = this;
yoho.goAddress({
type: '1'
type: '1',
addressid: this.address.addressId
}, (address) => {
if (address) {
self.$set('address', {
... ... @@ -132,7 +133,7 @@
zipCode: address.zip_code,
mobile: address.mobile,
address: address.address,
consigneeName: address.consignee_name
consignee: address.consignee
});
}
}, () => {
... ... @@ -151,7 +152,6 @@
goodsId: selection.size.goodsId,
sku: selection.size.value
};
console.log(goods.goodsId);
this.showFeatureSelector = false;
},
... ...
... ... @@ -131,6 +131,11 @@
this.brandData.splice(index, 1);
this.hideDelBth();
delete this.keys[id];
if (this.brandData.length === 0) {
this.nullbox = '';
this.updateNavBar();
}
} else if (data.code === 400) {
tip(data.message);
} else {
... ... @@ -209,7 +214,7 @@
}
},
updateNavBar() {
const header = $.extend({}, interceptClick.defaultTitleMap[5]);
const header = Object.assign({}, interceptClick.defaultTitleMap[5]);
header.defaultSelectedIndex = '1';
header.right.des = this.editmodel ? '完成' : '编辑';
... ... @@ -228,6 +233,12 @@
this.updateNavBar();
});
document.addEventListener('visibilitychange', function() {
if (yoho.isApp && !document.hidden) {
location.reload();
}
});
if (yoho.isApp) {
bus.$on('app.favourite.tabChange', this.updateNavBar);
}
... ...
<template>
<div class="fav-type" v-infinite-scroll="loadMore()" infinite-scroll-disabled="busy" infinite-scroll-distance="10" >
<div class="fav-type" v-infinite-scroll="loadMore()" infinite-scroll-disabled="busy" infinite-scroll-distance="10">
<ul class="fav-product-list">
<li v-for="item in productData" track-by="fav_id" id="li-{{item.fav_id}}"
v-touch-options:pan="{ direction: 'horizontal', threshold: 100}"
v-touch:panstart="panstart(item.fav_id)"
v-touch:panmove="panmove(item.fav_id)"
v-touch:panend="panend(item.fav_id)">
<div class="fav-del-left {{editmodel ? 'delshow': ''}}" @click="showDelBtn(item.fav_id)">
<span class="fav-del-span"><span class="icon icon-edit-del"></span></span>
</div>
<a :href="item | goodsUrl 'collection'">
<div class="fav-img-box">
<img :src="item.imgUrl | resize 152 203" alt=""/>
<div v-for="item in productData">
<li track-by="fav_id" id="li-{{item.fav_id}}" v-touch-options:pan="{ direction: 'horizontal', threshold: 100}" v-touch:panstart="panstart(item.fav_id)"
v-touch:panmove="panmove(item.fav_id)" v-touch:panend="panend(item.fav_id)">
<div class="fav-del-left {{editmodel ? 'delshow': ''}}" @click="showDelBtn(item.fav_id)">
<span class="fav-del-span"><span class="icon icon-edit-del"></span></span>
</div>
<div class="fav-info-list">
<span class="title line-clamp-2">{{item.title}}</span>
<br/>
<div class="fav-price">
<span class="new-price" v-if="item.discountPrice">{{item.discountPrice}}</span>
<span class="{{ item.discountPrice ? 'price-underline' : ''}}">{{item.price}}</span>
<a :href="item | goodsUrl 'collection'">
<div class="fav-img-box">
<img :src="item.imgUrl | resize 152 203" alt="" />
</div>
<br/>
<div class="save-price">
<span class="sell-out" v-if="item.sellOut || item.invalidGoods">{{item.sellOut ? '已售罄' : '已下架'}}</span>
<div class="fav-info-list">
<span class="title line-clamp-2">{{item.title}}</span>
<div class="fav-price">
<span class="new-price" v-if="item.discountPrice">{{item.discountPrice}}</span>
<!--<span class="{{ item.discountPrice ? 'price-underline' : ''}}">{{item.price}}</span>-->
</div>
<br/>
<div class="save-price">
<span class="sell-out" v-if="item.sellOut || item.invalidGoods">{{item.sellOut ? '已售罄' : '已下架'}}</span>
</div>
</div>
</a>
<div class="fav-del-right hide" id="del-{{item.fav_id}}" @click="delItem($index, item.fav_id)">
<span class="icon icon-delete"></span>
<br/>
<span class="fav-del-txt">删 除</span>
</div>
</a>
<div class="fav-del-right hide" id="del-{{item.fav_id}}" @click="delItem($index, item.fav_id)">
<span class="icon icon-delete"></span>
<br/>
<span class="fav-del-txt">删除</span>
</div>
</li>
</li>
<hr>
</div>
</ul>
<div class="fav-null-box {{ nullbox }}">
<span class="fav-null">您暂无收藏任何商品</span>
... ... @@ -147,6 +146,11 @@
this.productData.splice(index, 1);
this.hideDelBth();
delete this.keys[id];
if (this.productData.length === 0) {
this.nullbox = '';
this.updateNavBar();
}
} else if (data.code === 400) {
tip(data.message);
} else {
... ... @@ -224,7 +228,7 @@
}
},
updateNavBar() {
const header = $.extend({}, interceptClick.defaultTitleMap[5]);
const header = Object.assign({}, interceptClick.defaultTitleMap[5]);
header.defaultSelectedIndex = '0';
header.right.des = this.editmodel ? '完成' : '编辑';
... ... @@ -243,6 +247,12 @@
this.updateNavBar();
});
document.addEventListener('visibilitychange', function() {
if (yoho.isApp && !document.hidden) {
location.reload();
}
});
if (yoho.isApp) {
bus.$on('app.favourite.tabChange', this.updateNavBar);
}
... ... @@ -251,6 +261,10 @@
</script>
<style>
body {
background-color: #f6f6f6;
}
.yoho-favorite-page {
width: 100%;
height: auto;
... ... @@ -261,13 +275,21 @@
}
.fav-product-list {
padding-left: 20px;
list-style: none;
overflow: hidden;
padding-left: 30px;
background-color: #fff;
hr {
margin-right: 30px;
border: 1px solid #eee;
border-bottom: 0;
}
li {
position: relative;
height: 205px;
margin: 20px 0;
}
.fav-del-left {
... ... @@ -296,18 +318,20 @@
.fav-del-right {
position: absolute;
top: 0;
top: -20px;
right: -126px;
background: #ff3b30;
width: 126px;
height: 200px;
height: 245px;
text-align: center;
.icon-delete {
display: inline-block;
color: white;
font-size: 35px;
margin-top: 55px;
font-size: 36px;
margin-left: 8px;
margin-top: 80px;
margin-bottom: 16px;
}
.fav-del-txt {
... ... @@ -337,7 +361,7 @@
.fav-info-list {
color: #444;
font-size: 24px;
border-bottom: 1px solid #e0e0e0;
padding-right: 30px;
padding-bottom: 20px;
height: 203px;
overflow: hidden;
... ... @@ -347,15 +371,16 @@
width: 98%;
text-overflow: ellipsis;
font-size: 28px;
margin-top: 10px;
line-height: 32px;
color: #000;
}
.fav-price {
margin-top: 20px;
margin-top: 30px;
}
.new-price {
color: #d1021c;
color: #000;
font-size: 24px;
}
... ... @@ -368,7 +393,7 @@
.save-price {
position: absolute;
bottom: 20px;
bottom: 0;
left: 0;
width: 100%;
min-height: 24px;
... ... @@ -376,7 +401,7 @@
.sell-out {
float: right;
padding: 5px 18px;
padding: 0 30px;
color: #b0b0b0;
border-radius: 20px;
font-size: 22px;
... ...
<template>
<cheader title="我的" class="ghost" fixed v-ref:header>
<i slot="left" class="icon icon-setting" id="setting"></i>
</cheader>
<div class="my-header">
<a class="user-info auth" id="user-info" href='/me/mydetails'>
<span class="user-avatar" :style="data.headIco ? 'background-image: url(' + data.headIco + ')' : ''"></span>
</a>
<span class="username">{{ data.nickName }}</span>
</div>
<div class="my-order">
<a class="order-title auth" href="/me/order?type=1">
我的订单
<span class="read-order">
查看全部订单 <span class="icon icon-right"></span>
</span>
</a>
<div class="order-type clearfix">
<a class="type-item auth" href="/me/order?type=2">
<span class="icon icon-wait-pay"></span>
<br>待付款
<span class="num" v-if="data.waitPayNum">{{data.waitPayNum}}</span>
</a>
<a class="type-item auth" href='/me/order?type=3'>
<span class="icon icon-wait-cargo"></span>
<br>待发货
<span class="num" v-if="data.waitCargoNum">{{data.waitCargoNum}}</span>
</a>
<a class="type-item auth" href="/me/order?type=4">
<span class="icon icon-send-cargo"></span>
<br>待收货
<span class="num" v-if="data.sendCargoNum">{{data.sendCargoNum}}</span>
</a>
<a class="type-item auth" href="/me/return">
<span class="icon icon-refund-exchange"></span>
<br>退换货
<span class="num" v-if="data.refundExchangeNum">{{data.refundExchangeNum}}</span>
</a>
</div>
</div>
<div class="group-list">
<a class="glist-item auth" id="address">
地址管理
<span class="num">{{data.addressNum}} <span class="icon icon-right"></span></span>
</a>
</div>
<div class="group-list">
<a class="glist-item auth" href="/me/collection">
收藏的商品
<span class="num">{{data.productFavoriteTotal}} <span class="icon icon-right"></span></span>
</a>
<a class="glist-item auth" href="/me/collection?tab=brand">
收藏的品牌
<span class="num">{{data.brandFavoriteTotal}} <span class="icon icon-right"></span></span>
</a>
</div>
<div class="group-list">
<a class="glist-item auth" href="/me/mycurrency">
YOHO 币
<span class="num">{{data.yohoCoinNum}} <span class="icon icon-right"></span></span>
</a>
</div>
<div class="group-list">
<a class="glist-item" href="/help">
帮助中心
<span class="num"><span class="icon icon-right"></span></span>
</a>
<a class="glist-item" href="/me/service">
在线客服
<span class="num"><span class="icon icon-right"></span></span>
</a>
</div>
</template>
<script>
const yoho = require('yoho');
const $ = require('jquery');
const interceptClick = require('common/intercept-click');
const cheader = require('component/header.vue');
module.exports = {
data() {
return {
data: {}
};
},
components: {
cheader
},
methods: {
reload() {
$('#address').off('click', this.addressClick)
$('.auth').removeClass('no-intercept');
$('.auth').off('click', this.authClick);
if (yoho.isLogin()) {
$.ajax({
url: '/me/userdata'
}).then(result => {
this.data = result || {};
});
$('#address').on('click', this.addressClick);
} else {
this.data = {
nickName : '登录/注册'
};
$('.auth').addClass('no-intercept');
$('.auth').on('click', this.authClick);
}
},
addressClick() {
yoho.goAddress({
type: '2'
});
return false;
},
authClick(e) {
const id = $(e.target).attr('id');
const href = $(e.target).attr('href');
yoho.goLogin(null, () => {
this.reload();
setTimeout(() => {
if (id === 'address') {
yoho.goAddress({
type: '2'
});
} else if (href !== '/me/mydetails') {
interceptClick.intercept(href);
}
}, 200);
});
return false;
}
},
ready() {
this.reload();
$('#setting').on('click', function() {
yoho.goSetting();
return false;
});
window.addEventListener('touchmove', function() {
var topHeight = document.body.scrollTop;
if (topHeight > 50) {
$('#header').addClass('top-change');
} else {
$('#header').removeClass('top-change');
}
});
window.addEventListener('scroll', () => {
let transparent = true;
if (window.scrollY > 20 ) {
transparent = false;
}
this.$refs.header.$el.classList.toggle('ghost', transparent);
});
document.addEventListener('visibilitychange', () => {
if (!document.hidden) {
this.reload();
}
});
}
};
</script>
<style>
.my-page {
color: #444;
background: #f0f0f0;
a {
color: #000;
}
.blk-header-main {
position: absolute;
left: 0;
right: 0;
}
.top-box {
.blk-header {
background-color: transparent;
border-bottom: 0;
}
}
.top-change {
.blk-header {
background-color: #fff;
}
}
.my-header {
height: 469px;
background: resolve("me/header-bg.png");
background-size: cover;
}
.user-info {
display: block;
position: relative;
top: 145px;
padding: 0 30px;
margin: 0 180px;
color: #000;
font-size: 34px;
text-align: center;
.user-avatar {
display: inline-block;
position: relative;
width: 174px;
height: 174px;
border-radius: 50%;
margin: 0 auto;
border: 3px solid #b0b0b0;
background: resolve("me/user-icon.png");
background-size: 100%;
}
}
.username {
display: block;
text-align: center;
text-overflow: ellipsis;
white-space: nowrap;
font-size: 32px;
position: relative;
top: 140px;
}
.my-order {
margin-bottom: 20px;
border-top: 1px solid #eee;
border-bottom: 1px solid #eee;
background: #fff;
.order-title {
display: block;
padding: 0 30px;
font-size: 34px;
line-height: 88px;
position: relative;
&.highlight {
background: #eee;
}
.read-order {
color: #b0b0b0;
font-size: 30px;
float: right;
}
&:after {
content: "";
position: absolute;
left: 0;
bottom: 0;
width: 92%;
height: 0;
border-top: 1px solid #eee;
margin-left: 28px;
}
}
.order-type {
padding: 20px 0;
text-align: center;
.icon {
font-size: 45px;
}
.type-item {
position: relative;
float: left;
color: #444;
font-size: 24px;
line-height: 1.5;
width: 75px;
margin-left: 130px;
&.highlight {
background: #eee;
}
&:first-child {
margin-left: 34px;
}
.num {
position: absolute;
top: -35px;
right: -20px;
width: 72px;
height: 72px;
font-size: 34px;
line-height: 72px;
color: #fff;
background: #f03d35;
text-align: center;
border-radius: 50%;
transform: scale(0.5);
}
}
}
}
.group-list {
margin-bottom: 20px;
border-top: 1px solid #eee;
border-bottom: 1px solid #eee;
background: #fff;
.glist-item {
display: block;
position: relative;
padding: 0 30px;
font-size: 34px;
line-height: 88px;
overflow: hidden;
&.highlight {
background: #eee;
}
&:after {
content: "";
position: absolute;
left: 0;
bottom: 0;
width: 92%;
height: 0;
border-top: 1px solid #eee;
margin-left: 28px;
}
&:last-child:after {
content: none;
}
}
.icon {
font-size: 34px;
vertical-align: top;
}
.num {
color: #b0b0b0;
float: right;
}
}
}
.app.ios {
.blk-header {
padding-top: 80px;
}
}
</style>
... ...
... ... @@ -32,6 +32,7 @@
<div class="goods-price">
<p>&yen;{{product.goodsPrice}}</p>
<p>×{{product.buyNumber}}</p>
<p v-if="product.goodsStatus"><span class="goods-status">{{product.goodsStatus}}</span></p>
</div>
</a>
</li>
... ... @@ -66,7 +67,7 @@
const $ = require('jquery');
const tip = require('common/tip');
const Modal = require('common/modal');
const yohoAPI = require('yoho');
const yoho = require('yoho');
const interceptClick = require('common/intercept-click');
const genderSelect = require('common/select');
... ... @@ -85,7 +86,7 @@
this.updateNavBar();
this.getOrderData();
yohoAPI.addNativeMethod('goToService', () => {
yoho.addNativeMethod('goToService', () => {
interceptClick.intercept('/me/service');
return false;
});
... ... @@ -98,12 +99,14 @@
},
methods: {
updateNavBar() {
const header = $.extend({}, interceptClick.defaultTitleMap[2]);
const header = Object.assign({}, interceptClick.defaultTitleMap[2]);
header.title.des = '订单详情';
yohoAPI.updateNavigationBar({
header: header
});
setTimeout(() => {
yoho.updateNavigationBar({
header: header
});
}, 200);
},
reload() {
this.show = false;
... ... @@ -124,20 +127,20 @@
this.show = true;
this.$set('order', result.data);
this.genderSel = genderSelect([{
key: this.order.isSupportRefund,
val: this.order.isSupportRefund === 'Y' ? '申请退货' : '申请退货(已过期限)',
url: '/me/return/refund?orderCode=' + this.order.orderCode,
disabled: this.order.isSupportRefund !== 'Y'
}, {
key: this.order.isSupportExchange,
val: this.order.isSupportExchange === 'Y' ? '申请换货' : '申请换货(已过期限)',
url: '/me/return/exchange?orderCode=' + this.order.orderCode,
disabled: this.order.isSupportExchange !== 'Y'
}, {
key: 'onlineService',
val: '在线客服',
url: '/me/service'
}
key: this.order.isSupportRefund,
val: this.order.isSupportRefund === 'Y' ? '申请退货' : '申请退货(已过期限)',
url: '/me/return/refund?orderCode=' + this.order.orderCode,
disabled: this.order.isSupportRefund !== 'Y'
}, {
key: this.order.isSupportExchange,
val: this.order.isSupportExchange === 'Y' ? '申请换货' : '申请换货(已过期限)',
url: '/me/return/exchange?orderCode=' + this.order.orderCode,
disabled: this.order.isSupportExchange !== 'Y'
}, {
key: 'onlineService',
val: '在线客服',
url: '/me/service'
}
]);
if (Number(this.order.status) === 0) {
this.getCancelReason();
... ... @@ -152,7 +155,7 @@
});
},
reasonChange() {
if (this.cancelbusy) {
if (this.cancelbusy) {
return false;
}
... ... @@ -164,9 +167,12 @@
}, (result) => {
if (result.code === 200) {
tip('取消成功');
setTimeout(() => {
this.reload();
}, 1000);
yoho.store.set('orderReload', true);
} else if (result.code !== 500) {
tip(result.message);
}
... ... @@ -206,6 +212,7 @@
}, (result) => {
if (result.code === 200) {
this.reload();
yoho.store.set('orderReload', true);
}
});
};
... ... @@ -229,7 +236,8 @@
}
}).then(result => {
if (result.code === 200) {
yohoAPI.goBack();
yoho.goBack();
yoho.store.set('orderReload', true);
return false;
} else if (result.code !== 500) {
tip(result.message);
... ... @@ -253,6 +261,7 @@
}).then(result => {
if (result.code === 200) {
_this.reload();
yoho.store.set('orderReload', true);
} else if (result.code !== 500) {
tip(result.message);
}
... ... @@ -262,9 +271,11 @@
});
},
goBuy(order) {
yohoAPI.goPay({
yoho.goPay({
orderid: order.orderCode,
amount: order.amount
}, () => {
yoho.store.set('orderReload', true);
});
},
applyRefund() {
... ...
... ... @@ -3,7 +3,7 @@
<div class="overview">
<div class="left" >
<a href="{{logisticDate.url}}">
<img class="icon" v-bind:src="logo" />
<img class="icon" v-bind:src="logo | resize 88 88" />
</a>
</div>
<div class="right">
... ... @@ -174,6 +174,7 @@ $border_color_light: #eee;
let data = {
orderCode: qs.order_code || '',
type: qs.type || '',
id: qs.id || ''
};
$.ajax({
... ...
... ... @@ -30,7 +30,7 @@
</div>
</div>
<div class="order-option">
<div class="goods-total">合计: <b>&yen;{{order.amount}}</b></div>
<div class="goods-total">合计 <b>&yen;{{order.amount}}</b></div>
<div class="options">
<button v-if="order.isCancel === 'Y'" @click="deleteOrder(order,index)" class="normal">删除订单</button>
<template v-else>
... ... @@ -65,7 +65,7 @@
const $ = require('jquery');
const tip = require('common/tip');
const Modal = require('common/modal');
const yohoAPI = require('yoho');
const yoho = require('yoho');
module.exports = {
data() {
... ... @@ -89,7 +89,9 @@
document.addEventListener('visibilitychange', () => {
if (!document.hidden) {
this.reload();
if (yoho.store.get('orderReload')) {
this.reload();
}
}
});
},
... ... @@ -105,6 +107,8 @@
this.orderList = [];
this.getOrderData();
yoho.store.remove('orderReload');
},
getOrderData() {
this.busy = true;
... ... @@ -248,12 +252,14 @@
});
},
goBuy(order) {
yohoAPI.goPay({
yoho.goPay({
orderid: order.orderCode,
amount: order.amount
}, () => {
yoho.store.set('orderReload', true);
});
},
dropDown(elementId){
dropDown(elementId) {
let dropdown = document.getElementById(elementId);
this.showDropdown(dropdown);
... ...
... ... @@ -13,10 +13,10 @@
</div>
</li>
</ul>
<div v-if="detail.status == 20"
<div v-if="detail.status == 20 && detail.deliveryTpye != 20"
class="logistics-detail">
<template v-if="detail.notice">
<a href="/me/logistic?order_code={{sourceOrderCode}}&type=refund">
<a href="/me/logistic?order_code={{sourceOrderCode}}&id={{applyid}}&type={{type}}">
<h2>{{detail.notice.title}}</h2>
<p>物流公司: {{detail.notice.expressCompany}}<br>快递单号: {{detail.notice.expressNumber}}</p>
<span class="right"><span class="icon icon-right"></span></span>
... ... @@ -131,6 +131,7 @@
this.show = false;
this.detail = {};
yoho.store.remove('refundStatus');
$.ajax({
url: '/me/return/status-detail',
data: {
... ... @@ -147,8 +148,8 @@
this.id = this.detail.id;
this.sourceOrderCode = this.detail.sourceOrderCode;
} else if (result.code !== 500) {
tip(result.message);
} else if (res.code !== 500) {
tip(res.message);
} else {
tip('数据获取失败');
}
... ... @@ -170,7 +171,6 @@
url = '/me/return/exchange/cancel-apply';
}
Modal.confirm('', '确认取消吗?', function() {
this.hide();
$.ajax({
... ... @@ -193,7 +193,7 @@
this.reload();
document.addEventListener('visibilitychange', () => {
if (!document.hidden) {
if (!document.hidden && yoho.store.get('refundStatus')) {
this.reload();
}
});
... ...
<template>
<div class="edit-logistics-page">
<form class="edit-logistics">
<div class="edit-logistics">
<label @click="companylist">
选择快递公司<input class="company-val" type="text" value="{{company_name}}" readonly>
<span class="icon icon-right"></span>
... ... @@ -9,7 +9,7 @@
快递单号
<input class="num" maxlength="20" v-model='num'>
</label>
</form>
</div>
<div class="submit" @click="submit">确认</div>
</div>
</template>
... ... @@ -18,6 +18,7 @@
const $ = require('jquery');
const tip = require('common/tip');
const yoho = require('yoho');
const modal = require('common/modal');
module.exports = {
props: ['applyid', 'type', 'company_id', 'company_name'],
... ... @@ -42,27 +43,34 @@
return false;
}
$.ajax({
method: 'POST',
url: '/me/return/save-logistics',
data: {
applyid: this.applyid,
type: this.type,
expressId: this.company_id,
expressCompany: this.company_name,
expressNumber: this.num
}
}).then(res => {
if ($.type(res) !== 'object') {
res = {};
}
if (res.code !== 200) {
tip(res.message || '网络错误');
} else {
yoho.goBack();
}
const text = `快递公司:${this.company_name} <br>单号:${this.num}`;
const _this = this;
modal.confirm(text, '请确认寄回信息是否正确?', function() {
this.hide();
$.ajax({
url: '/me/return/save-logistics',
type: 'post',
data: {
applyid: _this.applyid,
type: _this.type,
expressId: _this.company_id,
expressCompany: _this.company_name,
expressNumber: _this.num
}
}).then(res => {
if ($.type(res) !== 'object') {
res = {};
}
if (res.code !== 200) {
tip(res.message || '网络错误');
} else {
yoho.goBack();
yoho.store.set('refundStatus', true);
return false;
}
});
});
return false;
}
}
};
... ...
... ... @@ -7,7 +7,7 @@
<img class="image" v-bind:src="product.goodsImage | resize 100 130">
<div class="info">
<div class="p-title">
{{product.productName}}{{product.productName}}{{product.productName}}{{product.productName}}
{{product.productName}}
</div>
<div class="meta">
<span class="color">颜色: {{product.colorName}}</span>
... ... @@ -17,7 +17,7 @@
<div class="price">
&yen;{{product.lastPrice}}
<p class="num">
x1
x{{product.num || 1}}
</p>
</div>
</div>
... ...
... ... @@ -160,7 +160,7 @@
</show-box>
<div class="control-box" v-if="isApp">
<div class="control-box" v-if="isApp && isReady">
<button class="button control-button">
<span @click="yoho.goShopingCart()" style="position: relative;">
<i class="icon icon-bag"></i>
... ... @@ -196,8 +196,8 @@
}
.show-box.brand {
$lh: 68px;
overflow: hidden;
$lh: 68px;
img {
height: 68px;
... ... @@ -223,7 +223,6 @@
line-height: $lh;
color: #b0b0b0;
}
}
.product-detail-desc {
... ... @@ -232,6 +231,10 @@
width: 100% !important;
height: auto !important;
}
table {
width: 100%;
}
}
i.info {
... ... @@ -273,7 +276,6 @@
&.highlight {
color: #d0021b;
}
}
}
... ... @@ -328,7 +330,6 @@
line-height: 66px;
text-align: center;
}
}
.wash-condition {
... ... @@ -355,7 +356,6 @@
color: #c7c7c7;
min-width: 100px;
}
}
.model-avatar {
... ... @@ -392,7 +392,6 @@
data() {
return {
yoho: yoho,
isApp: yoho.isApp,
intro: {},
firstImage: '',
entity: {
... ... @@ -427,18 +426,20 @@
this.cartCount = result.data.goods_count;
selector.playAnimation();
}
}
this.showFeatureSelector = false;
tip(result.message);
});
}
},
//state
isApp: yoho.isApp,
isSoldOut: false,
isReady: false
};
},
computed: {
isSoldOut: function() {
return this.entity.storage === 0;
}
},
components: {
imageCarousel: require('./image-carousel.vue'),
... ... @@ -500,6 +501,10 @@
// TODO: 异常处理
this.entity = result;
if (this.entity.storage === 0 || this.entity.status === 0) {
this.isSoldOut = true;
}
this.entity.goodsList.forEach((goods)=> {
if (!this.firstImage && goods.colorImage) {
this.firstImage = goods.colorImage;
... ... @@ -527,7 +532,8 @@
$.get(`/product/product/intro_${pid}.json`, {skn: result.productPriceBo.productSkn}).then(intro => {
this.intro = intro;
});
});
})
.always(()=>{this.isReady = true});
// 读取购物车数量
if (this.isApp) {
... ...
... ... @@ -5,6 +5,12 @@
</template>
<style>
.product-header {
&.ghost {
.blk-header-title {
visibility: hidden;
}
}
.blk-header-gap {
display: none;
}
... ...
... ... @@ -131,7 +131,6 @@
});
bus.$on('order.change', function({val}) {
console.log(val);
self.order = val;
});
... ...
... ... @@ -60,7 +60,6 @@
const self = this;
const nextPage = this.page + 1;
console.log(nextPage);
if (this.inSearching) {
return;
}
... ... @@ -130,7 +129,6 @@
* 2. 关闭 drawer 组件
*/
bus.$on('filter.change', function({val}) {
console.log(val);
let filter = {};
$.each(val, (type, item) => {
... ...
... ... @@ -90,7 +90,8 @@
title: result.shopName,
des: shareSubTitle,
url: shareUrl,
img: result.shopLogo ? result.shopLogo : '',
img: result.shopLogo ? result.shopLogo.split('?')[0] +
'?imageMogr2/thumbnail/300x300/format/jpg/quality/90' : '',
isBlkShop: result.isBlkShop,
domain: locationQuery.domain,
brandName: result.brandName,
... ...
<template>
<cheader :title="title" :class='topClass'>
<cheader :title="title" class="ghost" fixed v-ref:header>
<template slot="right">
<span v-if="shareData.isBlkShop" v-show="shareData.isFav" class="icon" @click="collectShop()">&#xe60d;</span>
<span v-if="shareData.isBlkShop" v-show="!shareData.isFav" class="icon" @click="collectShop()">&#xe60c;</span>
... ... @@ -10,28 +10,9 @@
</template>
<style>
.blk-header-gap {
display: none;
}
.blk-header {
transition: 0.3s all;
}
.top-box {
.blk-header {
background-color: transparent;
color: #fff;
border-bottom: 0;
}
}
.top-change {
.blk-header {
background-color: #fff;
color: #000;
}
}
</style>
<script>
... ... @@ -41,9 +22,7 @@
module.exports = {
data() {
return {
topChange: false
};
return {};
},
props: {
shareData: {
... ... @@ -51,12 +30,6 @@
}
},
computed: {
topClass() {
return {
'top-change': this.topChange || !this.shareData.isBlkShop,
'top-box': true
};
},
title() {
let result = '';
... ... @@ -106,13 +79,14 @@
this.$parent.$refs.filter.isVisible = !this.$parent.$refs.filter.isVisible;
},
changeTopStatus() {
let topChange = true;
let topHeight = document.body.scrollTop;
if (topHeight > 100) {
this.topChange = true;
} else {
this.topChange = false;
}
topChange = false;
}
this.$refs.header.$el.classList.toggle('ghost', topChange);
}
},
created() {
... ...
... ... @@ -24,6 +24,7 @@ shelljs.ls(path.join(__dirname, 'js/**/*.page.js')).forEach((f) => {
entries.libs = [
'yoho-qs',
'yoho-cookie',
'yoho-store',
'jquery',
'vue',
'vue-lazyload',
... ...