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
79ac0b67
Commit
79ac0b67
authored
Aug 08, 2022
by
songbingqi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
退款详情页面联调
parent
f5f34e51
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
136 additions
and
42 deletions
+136
-42
orderSubPackage/pages/refundInfo/index.vue
+136
-42
No files found.
orderSubPackage/pages/refundInfo/index.vue
View file @
79ac0b67
...
...
@@ -2,25 +2,25 @@
<view
class=
"big"
>
<view
class=
"refundStep"
>
<view
class=
"refund_title"
>
退款进程
</view>
<view
class=
"refund_list"
>
<view
:class=
"i
tem.status===1?'refund_item_action':'refund_item'"
v-for=
"(item,index) in newL
ist"
:key=
"index"
>
<view
class=
"refund_list"
v-for=
"(item,index) in newList"
>
<view
:class=
"i
ndex===0?'refund_item_action':'refund_item'"
v-for=
"(listItem,index) in item.l
ist"
:key=
"index"
>
<view
class=
"item"
>
<view
:class=
"i
tem.status===1
?'refund_info_action':'refund_info'"
>
<view
:class=
"i
tem.status===1
?'info_ciycle_action':'info_ciycle'"
></view>
<view
:class=
"i
ndex===0
?'refund_info_action':'refund_info'"
>
<view
:class=
"i
ndex===0
?'info_ciycle_action':'info_ciycle'"
></view>
<view
class=
"info_text"
>
<view
:class=
"i
tem.status===1?'info_title_action':'info_title'"
>
{{
i
tem
.
title
}}
</view>
<view
:class=
"i
tem.status===1?'info_time_action':'info_time'"
>
2022年6月2日09:35:27
</view>
<view
:class=
"i
ndex===0?'info_title_action':'info_title'"
>
{{
listI
tem
.
title
}}
</view>
<view
:class=
"i
ndex===0?'info_time_action':'info_time'"
>
{{
listItem
.
time
}}
</view>
</view>
</view>
</view>
</view>
</view>
<view
class=
"morInfo"
v-if=
"list.length>
4
"
@
click=
"watchMore"
>
<view
class=
"morInfo"
v-if=
"list.length>
1
"
@
click=
"watchMore"
>
<view>
更多退款信息
</view>
<view
class=
"function_item_icon"
>
<image
:style=
"
{'height':'100%','width':'100%'}" :src="'../../../static/imgs/jiantoulan.png'" />
<image
:style=
"
{'height':'100%','width':'100%'}" :
class="['arrow-right-select',flag?'arrow-right-select-down':'arrow-right-select-right']" :
src="'../../../static/imgs/jiantoulan.png'" />
</view>
</view>
</view>
...
...
@@ -35,53 +35,107 @@ export default {
flag
:
false
,
list
:[
{
title
:
'退款成功'
,
time
:
'2022年6月2日09:35:27'
,
status
:
0
},
{
title
:
'退款中'
,
time
:
'2022年6月2日09:35:27'
,
status
:
1
},
{
title
:
'审核中'
,
time
:
'2022年6月2日09:35:27'
,
status
:
0
},
{
title
:
'退款申请已提交'
,
time
:
'2022年6月2日09:35:27'
,
status
:
0
},
{
title
:
'退款申请已提交'
,
time
:
'2022年6月2日09:35:27'
,
status
:
0
},
skuName
:
''
,
list
:
[{
title
:
'待退款'
,
time
:
'2022年6月2日09:35:27'
,
state
:
0
,
},
{
title
:
'退款中'
,
time
:
'2022年6月2日09:35:27'
,
state
:
1
,
},
{
title
:
'退款成功'
,
time
:
'2022年6月2日09:35:27'
,
state
:
2
,
},
{
title
:
'退款失败'
,
time
:
'2022年6月2日09:35:27'
,
state
:
3
,
}]
}
],
oldList
:[],
newList
:[]
};
},
mounted
()
{
if
(
this
.
list
.
length
>
4
){
this
.
newList
=
[...
this
.
list
].
splice
(
0
,
4
)
this
.
flag
=
false
}
else
{
this
.
newList
=
this
.
list
}
this
.
getRefundInfo
()
},
methods
:{
async
getRefundInfo
(){
let
orderId
=
uni
.
getStorageSync
(
'orderId'
);
const
{
data
}
=
await
order
.
getRefundInfo
(
orderId
);
console
.
log
(
data
)
const
statusDesc
=
[
{
state
:
0
,
desc
:
'待退款'
},
{
state
:
1
,
desc
:
'退款中'
},
{
state
:
2
,
desc
:
'退款成功'
},
{
state
:
3
,
desc
:
'退款失败'
},
]
const
newList
=
[]
const
test
=
[{
state
:
3
,
createdAt
:
'111'
,
updatedAt
:
'222'
},
{
state
:
2
,
createdAt
:
'111'
,
updatedAt
:
'222'
}
]
data
.
data
.
map
(
item
=>
{
const
list
=
[]
for
(
let
i
=
0
;
i
<=
item
.
state
;
i
++
){
const
time
=
''
if
(
i
===
0
||
i
===
1
){
time
=
item
.
createdAt
}
else
{
time
=
item
.
updatedAt
}
list
.
push
({
title
:
statusDesc
[
i
].
desc
,
time
:
time
,
state
:
i
})
if
(
i
===
3
){
list
.
splice
(
2
,
1
)
}
}
newList
.
push
({
skuName
:
''
,
list
:
list
.
sort
((
a
,
b
)
=>
{
return
b
.
state
-
a
.
state
})
})
})
this
.
list
=
newList
if
(
this
.
list
.
length
>
1
){
this
.
newList
=
[...
this
.
list
].
splice
(
0
,
1
)
this
.
flag
=
false
}
else
{
this
.
newList
=
this
.
list
}
console
.
log
(
newList
,
this
.
newList
)
},
watchMore
(){
if
(
this
.
flag
){
this
.
newList
=
[...
this
.
list
].
splice
(
0
,
4
)
this
.
newList
=
[...
this
.
list
].
splice
(
0
,
1
)
}
else
{
this
.
newList
=
this
.
list
}
...
...
@@ -106,7 +160,7 @@ export default {
.refund_title
{
margin
:
38
rpx
30
rpx
;
height
:
44
rpx
;
margin-bottom
:
42
rpx
;
margin-bottom
:
0
rpx
;
font-size
:
32
rpx
;
font-family
:
PingFangSC-Medium
,
PingFang
SC
;
font-weight
:
500
;
...
...
@@ -114,7 +168,8 @@ export default {
line-height
:
44
rpx
;
}
.refund_list
{
margin
:
0
rpx
32
rpx
0
rpx
35
rpx
;
margin
:
38
rpx
32
rpx
0
rpx
35
rpx
;
//
margin-top
:
32
rpx
;
.refund_item
{
height
:
100
rpx
;
...
...
@@ -220,6 +275,14 @@ export default {
}
}
.refund_list
:nth-child
(
1
)
{
margin-top
:
38px
;
}
.refund_list
:nth-child
(
n
+
3
)
{
margin-top
:
38px
;
}
.morInfo
{
margin-top
:
40
rpx
;
margin-right
:
32
rpx
;
...
...
@@ -236,6 +299,37 @@ export default {
margin-left
:
6
rpx
;
width
:
11.27
rpx
;
height
:
15.68
rpx
;
.arrow-right-select-down
{
animation-name
:
upAnidown
;
animation-duration
:
0s
;
animation-fill-mode
:
forwards
;
@keyframes
upAnidown
{
0%
{
transform
:
rotate
(
0
);
-webkit-transform
:
rotate
(
0
);
}
100
%
{
transform
:
rotate
(
-90deg
);
-webkit-transform
:
rotate
(
-90deg
);
}
}
}
;
.arrow-right-select-right
{
animation-name
:
upAniup
;
animation-duration
:
0s
;
animation-fill-mode
:
forwards
;
@keyframes
upAniup
{
0%
{
transform
:
rotate
(
90deg
);
-webkit-transform
:
rotate
(
90deg
);
}
100
%
{
transform
:
rotate
(
0deg
);
-webkit-transform
:
rotate
(
0deg
);
}
}
}
}
}
}
...
...
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