Authored by yyq

Merge branch 'feature/refund' into release/6.6

... ... @@ -6,6 +6,14 @@
const helpers = global.yoho.helpers;
const returnsModel = require('../models/returns');
// 退货时传退货收件地址
const GOODS_BACK_ADDRESS = {
address: '江苏南京市江宁经济开发区苏源大道87号YOHO!有货物流中心东一楼',
name: 'YOHO!有货仓库',
phone: '400-889-9646',
postcode: '211106'
};
/**
* 我的退换货-列表页
*/
... ... @@ -57,12 +65,7 @@ const refundSuccess = (req, res) => {
type: '退货',
ordersHref: helpers.urlFormat('/home/orders'),
returnsHref: helpers.urlFormat('/home/returns'),
refund: {// 退货时传退货收件地址
address: '南京市江宁区江宁经济技术开发区苏源大道87号YOHO!有货物流中心东一楼',
name: 'YOHO!有货',
phone: '400-889-9646',
postcode: '211106'
}
refund: GOODS_BACK_ADDRESS
}
};
... ... @@ -92,7 +95,8 @@ const refundDetail = (req, res, next) => {
const uid = req.user.uid;
let resData = {
module: 'home',
page: 'returns'
page: 'returns',
backAddress: GOODS_BACK_ADDRESS
};
req.ctx(returnsModel).getRefundDetail(code, uid).then(result => {
... ...
... ... @@ -371,7 +371,8 @@ module.exports = class extends global.yoho.BaseModel {
id: _.get(data, 'notice.express_id', ''),
company: _.get(data, 'notice.express_company', ''),
number: _.get(data, 'notice.express_number', ''),
title: _.get(data, 'notice.title', '')
title: _.get(data, 'notice.title', ''),
titleClass: 'red'
};
}
... ...
... ... @@ -31,10 +31,30 @@
<div class="detail-container">
{{# express}}
{{#if title}}
<h2>{{title}}</h2>
<h2 class="{{titleClass}}">{{title}}</h2>
{{else}}
<h2>请填写寄回快递单号,以便我们查询</h2>
{{/if}}
{{# @root.backAddress}}
<div class="back-info clearfix">
<div class="left-address left">
<p><span class="lt">寄回地址</span>{{address}}</p>
<p><span class="lt">收件人</span>{{name}}</p>
<p><span class="lt">联系电话</span>{{phone}}</p>
<p><span class="lt">邮编</span>{{postcode}}</p>
</div>
<div class="right-mind left">
<p class="mind-title">注意事项</p>
<ul>
<li>确保商品及其附件(如吊牌、包装盒等)完好,未使用</li>
<li>邮政平邮或者到付件仓库无法签收,请勿寄送哦</li>
<li class="red">发货单随同商品一并寄回;如发货单遗失,请以便签附上订单 编号、收货人姓名及手机号</li>
</ul>
</div>
</div>
{{/ @root.backAddress}}
<div class="courier-code{{#unless id}} in-edit{{/unless}}">
<ul style="display: none;">
{{# expressList}}
... ... @@ -117,7 +137,7 @@
{{/goods}}
<tr>
<td colspan="5">
<p class="re-tips">{{#if return_amount}}退款总金额:¥{{return_amount}} {{#if return_asset_desc}}({{return_asset_desc}}){{/if}}<span class="iconfont icon-tip-help">&#xe6d6;</span>{{/if}}</p>
<p class="re-tips">{{#if return_amount}}退款总金额:¥{{return_amount}} <span class="iconfont icon-tip-help">&#xe6d6;</span>{{/if}} {{#if return_asset_desc}}<span class="gray">{{return_asset_desc}}</span>{{/if}}</p>
</td>
</tr>
</table>
... ...
{{#if return_amount}}退款总金额:¥{{return_amount}} {{#if return_asset_desc}}({{return_asset_desc}}){{/if}}<span class="iconfont icon-tip-help">&#xe6d6;</span>{{/if}}
{{#if return_amount}}退款总金额:¥{{return_amount}} <span class="iconfont icon-tip-help">&#xe6d6;</span>{{/if}} {{#if return_asset_desc}}<span class="gray">{{return_asset_desc}}</span>{{/if}}
... ...
... ... @@ -158,9 +158,14 @@
font-size: 15px;
color: #d1071f;
vertical-align: top;
margin-left: 5px;
margin: 0 5px;
cursor: pointer;
}
.gray {
color: #999;
font-size: 12px;
}
}
.problem-description {
... ...
... ... @@ -38,7 +38,7 @@
h2 {
height: 21px;
line-height: 21px;
line-height: 22px;
padding-left: 23px;
background: resolve(home/complaint-icon.png) no-repeat 5px 5px #efefef;
border: 1px #e6e6e6 solid;
... ... @@ -48,8 +48,88 @@
margin: 10px 0;
}
.red {
color: #cd0c25;
}
.back-info {
background-color: #f7f7f7;
border: 1px solid #e0e0e0;
padding: 13px 20px;
box-sizing: border-box;
position: relative;
&:before {
content: "";
border-left: 1px solid #ebebeb;
position: absolute;
left: 50%;
top: 28px;
bottom: 28px;
}
.left-address {
width: 50%;
padding-left: 68px;
padding-right: 20px;
font-size: 13px;
line-height: 1.7;
color: #000;
position: relative;
box-sizing: border-box;
.lt {
width: 54px;
text-align: justify;
text-align-last: justify;
position: absolute;
left: 0;
}
.lt:after {
content: ":";
position: absolute;
margin-right: -4px;
}
}
.right-mind {
width: 49%;
padding-left: 20px;
box-sizing: border-box;
.mind-title {
font-size: 13px;
line-height: 1.7;
color: #999;
}
ul {
color: #666;
line-height: 1.5;
padding-left: 16px;
position: relative;
}
li {
margin-top: 4px;
}
li:before {
content: "●";
color: #b0b0b0;
position: absolute;
left: 0;
}
.red:before {
color: #cd0c25;
}
}
}
.courier-code {
margin: 60px auto;
margin: 30px auto;
text-align: center;
.express-edit-box {
... ... @@ -178,9 +258,14 @@
font-size: 15px;
color: #d1071f;
vertical-align: top;
margin-left: 5px;
margin: 0 5px;
cursor: pointer;
}
.gray {
color: #999;
font-size: 12px;
}
}
p.line-through {
... ...