Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
peizhen-java
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
PeiZhen-Java
peizhen-java
Commits
0e85e266
Commit
0e85e266
authored
Oct 07, 2023
by
sdif
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
区分APP和小程序支付类型
parent
fca31f6c
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
2 deletions
+15
-2
pz-system/src/main/java/com/pz/system/domain/bo/TotalOrderBo.java
+5
-0
pz-system/src/main/java/com/pz/system/service/impl/TotalOrderServiceImpl.java
+10
-2
No files found.
pz-system/src/main/java/com/pz/system/domain/bo/TotalOrderBo.java
View file @
0e85e266
...
...
@@ -117,4 +117,9 @@ public class TotalOrderBo extends BaseEntity {
* pc是否同意退款1-完成退款,2-取消退款
*/
private
Integer
isPcRefundStatus
;
/**
* 区分APP和小程序支付(0小程序1APP)
*/
private
Integer
paymentType
;
}
pz-system/src/main/java/com/pz/system/service/impl/TotalOrderServiceImpl.java
View file @
0e85e266
...
...
@@ -745,13 +745,21 @@ public class TotalOrderServiceImpl implements ITotalOrderService {
orderRequest
.
setBody
(
bo
.
getOrderTitle
());
orderRequest
.
setOutTradeNo
(
totalOrder
.
getOrderSn
());
orderRequest
.
setTotalFee
(
money
);
// 元转成分
if
(
StringUtils
.
isNotEmpty
(
openId
)){
if
(
null
!=
bo
.
getPaymentType
()){
if
(
bo
.
getPaymentType
()
==
0
){
orderRequest
.
setOpenid
(
openId
);
orderRequest
.
setTradeType
(
"JSAPI"
);
}
else
if
(
bo
.
getPaymentType
()
==
1
){
orderRequest
.
setTradeType
(
"APP"
);
}
}
else
{
orderRequest
.
setOpenid
(
openId
);
orderRequest
.
setTradeType
(
"JSAPI"
);
}
orderRequest
.
setSpbillCreateIp
(
"127.0.0.1"
);
orderRequest
.
setNotifyUrl
(
"https://peizheng.shanpeikj.com/api/applet/totalOrder/orderPayCallBack"
);
orderRequest
.
setTradeType
(
"JSAPI"
);
payment
=
iPayService
.
createOrder
(
orderRequest
);
}
catch
(
Exception
e
)
{
...
...
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