Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
phsl
/
admin
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
74e04279
authored
Sep 24, 2024
by
YunaiV
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
【功能优化】支付:查询支付订单时,增加 sync 主动轮询,解决支付宝、微信存在延迟的问题
parent
da45ee03
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
3 deletions
+9
-3
src/api/pay/order/index.ts
+8
-2
src/views/pay/cashier/index.vue
+1
-1
No files found.
src/api/pay/order/index.ts
View file @
74e04279
...
...
@@ -84,8 +84,14 @@ export const getOrderPage = async (params: OrderPageReqVO) => {
}
// 查询详情支付订单
export
const
getOrder
=
async
(
id
:
number
)
=>
{
return
await
request
.
get
({
url
:
'/pay/order/get?id='
+
id
})
export
const
getOrder
=
async
(
id
:
number
,
sync
?:
boolean
)
=>
{
return
await
request
.
get
({
url
:
'/pay/order/get'
,
params
:
{
id
,
sync
}
})
}
// 获得支付订单的明细
...
...
src/views/pay/cashier/index.vue
View file @
74e04279
...
...
@@ -231,7 +231,7 @@ const getDetail = async () => {
goReturnUrl
(
'cancel'
)
return
}
const
data
=
await
PayOrderApi
.
getOrder
(
id
.
value
)
const
data
=
await
PayOrderApi
.
getOrder
(
id
.
value
,
true
)
payOrder
.
value
=
data
// 1.2 无法查询到支付信息
if
(
!
data
)
{
...
...
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