Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
U
user
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
hooloo
mp
user
Commits
f5f34e51
Commit
f5f34e51
authored
Aug 07, 2022
by
songbingqi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
调整结算页面部分字段
parent
c9598a8f
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
27 additions
and
13 deletions
+27
-13
mineSubPackage/pages/userInfo/index.vue
+4
-2
orderSubPackage/pages/orderInfo/index.vue
+4
-4
orderSubPackage/pages/refundInfo/index.vue
+7
-0
request/order/index.js
+10
-0
utils/utils.js
+2
-7
No files found.
mineSubPackage/pages/userInfo/index.vue
View file @
f5f34e51
...
...
@@ -76,6 +76,7 @@ export default {
const
years
=
date
.
getFullYear
()
const
month
=
date
.
getMonth
()
+
1
const
days
=
date
.
getDate
()
return
years
+
'.'
+
month
+
'.'
+
days
}
},
...
...
@@ -142,10 +143,11 @@ export default {
this
.
userInfo
.
id
=
id
this
.
canEditBirthday
=
!
birthday
if
(
!
birthday
){
this
.
userInfo
.
birthday
=
Date
.
parse
(
createTime
)
this
.
userInfo
.
birthday
=
new
Date
(
createTime
.
replace
(
/-/g
,
'/'
)).
valueOf
(
)
}
else
{
this
.
userInfo
.
birthday
=
Date
.
parse
(
birthday
)
this
.
userInfo
.
birthday
=
new
Date
(
birthday
.
replace
(
/-/g
,
'/'
)).
valueOf
(
)
}
this
.
userInfo
.
avatarUrl
=
avatarUrl
this
.
userInfo
.
sex
=
sex
?
sex
?
1
:
0
:
gender
this
.
userInfo
.
name
=
userName
?
userName
:
nickName
...
...
orderSubPackage/pages/orderInfo/index.vue
View file @
f5f34e51
...
...
@@ -61,7 +61,7 @@
<div
class=
"goods_text"
>
<div
class=
"goods_name"
>
<div
class=
"name"
>
{{
item
.
goodsName
}}
</div>
<div
class=
"price"
>
¥
{{
Utils
.
isInteger
(
item
.
realAmount
)
}}
</div>
<div
class=
"price"
>
¥
{{
Utils
.
isInteger
(
item
.
unitPrice
)
}}
</div>
</div>
<div
class=
"goods_psce"
>
<div
class=
"psce_name"
>
...
...
@@ -80,7 +80,7 @@
<div
class=
"coupon"
v-if=
"orderInfo.couponAmount"
>
<div
class=
"title"
>
HOOLOO券
</div>
<div
class=
"num-action"
>
<span
class=
"price"
>
-¥
{{
orderInfo
.
couponAmount
}}
</span>
<span
class=
"price"
>
-¥
{{
String
(
orderInfo
.
couponAmount
).
replace
(
"-"
,
""
)
}}
</span>
</div>
</div>
...
...
@@ -88,7 +88,7 @@
<div
class=
"size"
>
共
{{
totalNum
}}
件商品
</div>
<div
class=
"price"
>
<span
class=
"paid_in"
>
实付
</span>
<span
class=
"money"
><text
class=
"money_logo"
>
¥
</text>
{{
Utils
.
isInteger
(
orderInfo
.
a
mount
)
}}
</span>
<span
class=
"money"
><text
class=
"money_logo"
>
¥
</text>
{{
Utils
.
isInteger
(
orderInfo
.
paidA
mount
)
}}
</span>
</div>
</div>
</div>
...
...
@@ -289,7 +289,7 @@ export default {
title
:
'确认退款'
,
success
:
(
res
)
=>
{
if
(
res
.
confirm
)
{
Order
.
orderRefund
({
orderId
:
this
.
orderInfo
.
id
,
refundAmount
:
this
.
orderInfo
.
a
mount
}).
then
(
res
=>
{
Order
.
orderRefund
({
orderId
:
this
.
orderInfo
.
id
,
refundAmount
:
this
.
orderInfo
.
paidA
mount
}).
then
(
res
=>
{
this
.
initData
()
})
}
else
if
(
res
.
cancel
)
{
...
...
orderSubPackage/pages/refundInfo/index.vue
View file @
f5f34e51
...
...
@@ -28,6 +28,7 @@
</
template
>
<
script
>
import
order
from
'@/request/order'
export
default
{
data
()
{
return
{
...
...
@@ -70,8 +71,14 @@ export default {
}
else
{
this
.
newList
=
this
.
list
}
this
.
getRefundInfo
()
},
methods
:{
async
getRefundInfo
(){
let
orderId
=
uni
.
getStorageSync
(
'orderId'
);
const
{
data
}
=
await
order
.
getRefundInfo
(
orderId
);
console
.
log
(
data
)
},
watchMore
(){
if
(
this
.
flag
){
this
.
newList
=
[...
this
.
list
].
splice
(
0
,
4
)
...
...
request/order/index.js
View file @
f5f34e51
...
...
@@ -125,5 +125,15 @@ export default {
// uni.showToast({ title: '服务器错误', icon: 'none' })
console
.
log
(
'服务器错误'
);
});
},
// 获取退款详情
getRefundInfo
(
params
)
{
return
uni
.
$u
.
http
.
get
(
`/system/refund/list/
${
params
}
`
)
.
then
((
res
)
=>
res
)
.
catch
((
err
)
=>
{
// uni.showToast({ title: '服务器错误', icon: 'none' })
console
.
log
(
'服务器错误'
);
});
}
};
utils/utils.js
View file @
f5f34e51
...
...
@@ -6,7 +6,7 @@ import { $EventBus } from './EventBus';
export
default
{
// 组装提交订单数据
AssemblyOrder
(
shopData
,
totalPrice
,
totalNum
,
buyType
,
shopCarInfo
)
{
if
(
shopCarInfo
&&
total
Price
>
0
&&
total
Num
>
0
)
{
if
(
shopCarInfo
&&
totalNum
>
0
)
{
let
orderDetails
=
[];
for
(
let
i
=
0
;
i
<
shopCarInfo
.
length
;
i
++
)
{
let
item
=
shopCarInfo
[
i
];
...
...
@@ -161,11 +161,6 @@ export default {
}
},
isInteger
(
value
)
{
const
val
=
Number
(
value
)
if
(
val
%
1
===
0
){
return
parseInt
(
val
)
}
else
{
return
val
.
toFixed
(
1
)
}
return
parseFloat
(
Number
(
value
).
toFixed
(
2
))
}
};
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment