Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
yohobuywap-node
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
0
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Plain Diff
Browse Files
Authored by
zhangxiaoru
8 years ago
Commit
7bc79aaffb6b77da16a815bc2e7ec8442e75e107
2 parents
9dce4b5d
270e2f40
merge
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
4 deletions
apps/home/models/orderDetail.js
apps/home/views/action/orderDetail.hbs
apps/home/models/orderDetail.js
View file @
7bc79aa
...
...
@@ -60,6 +60,10 @@ const _getOrderStatus = (order, showLogistics) => {
// 先判断订单付款方式,根据不同的付款方式计算订单状态。(注:货到付款没有待付款状态)
// 支付方式为非货到付款时,计算订单状态。
if
(
parseInt
(
order
.
paymentType
,
10
)
!==
2
)
{
Object
.
assign
(
result
,
{
isPayonline
:
true
});
switch
(
order
.
status
)
{
case
0
:
...
...
@@ -75,7 +79,8 @@ const _getOrderStatus = (order, showLogistics) => {
/* 已付款状态不给查看物流 URL */
Object
.
assign
(
result
,
{
unreceived
:
true
unreceived
:
true
,
payAly
:
true
});
break
;
case
4
:
...
...
@@ -83,7 +88,8 @@ const _getOrderStatus = (order, showLogistics) => {
/* 已发货状态,给查看物流或二维码URL */
Object
.
assign
(
result
,
{
unreceived
:
true
unreceived
:
true
,
payAly
:
true
});
/* 是否门票 */
...
...
@@ -99,7 +105,8 @@ const _getOrderStatus = (order, showLogistics) => {
/* 已成功订单,给查看物流或二维码URL */
Object
.
assign
(
result
,
{
completed
:
true
completed
:
true
,
payAly
:
true
});
/* 是否门票 */
...
...
@@ -115,6 +122,10 @@ const _getOrderStatus = (order, showLogistics) => {
break
;
}
}
else
{
Object
.
assign
(
result
,
{
payAly
:
true
,
paymentName
:
(
order
.
paymentName
!==
''
)
?
order
.
paymentName
:
'货到付款'
});
/* 订单为货到付款订单时,计算订单状态。(货到付款没有待付款状态) */
switch
(
order
.
status
)
{
...
...
@@ -303,6 +314,8 @@ const orderDetailData = (uid, orderCode) => {
cancelReason
:
resons
});
//console.log(orderDetail)
return
orderDetail
;
});
...
...
apps/home/views/action/orderDetail.hbs
View file @
7bc79aa
...
...
@@ -36,6 +36,9 @@
<span
class=
"sub-title"
>
订单编号:
{{
orderCode
}}
</span>
<span
>
订单状态:
{{
statusStr
}}
</span>
<span>
下单时间:
<b
class=
"createTime"
>
{{
createTime
}}
</b></span>
{{#if
payAly
}}
<span>
支付方式:
{{
paymentName
}}
</span>
{{/if}}
</p>
<a
href=
"
{{
serviceUrl
}}
"
target=
"_blank"
class=
"iconfont icon-right"
>

</a>
</div>
...
...
@@ -71,7 +74,7 @@
</li>
{{/
each
}}
<li>
实付金额
{{#if
isPayonline
}}
实付金额
{{else}}
应付金额
{{/if}}
<span>
{{
amount
}}
</span>
</li>
</ul>
...
...
Please
register
or
login
to post a comment