Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
S
shop
Project
Project
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
曲欣亮
shop
Commits
7493a769
Commit
7493a769
authored
May 06, 2024
by
张永
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
V1.1.7.6
parent
baadc1bc
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
95 additions
and
46 deletions
+95
-46
pom.xml
pom.xml
+1
-1
OrderController.java
src/main/java/com/egolm/shop/api/OrderController.java
+1
-1
PayNotifyController.java
src/main/java/com/egolm/shop/api/PayNotifyController.java
+10
-5
OrderService.java
src/main/java/com/egolm/shop/api/service/OrderService.java
+4
-4
OrderServiceImpl.java
...ava/com/egolm/shop/api/service/impl/OrderServiceImpl.java
+74
-33
application.properties
src/main/resources/application.properties
+3
-2
redmine.html
src/main/resources/templates/redmine.html
+2
-0
No files found.
pom.xml
View file @
7493a769
...
...
@@ -209,7 +209,7 @@
</executions>
<configuration>
<repository>
dockerhub.linkfern.com/b2c/shopapi
</repository>
<tag>
V1.1.7.
5
</tag>
<tag>
V1.1.7.
6
</tag>
<buildArgs>
<JAR_FILE>
${project.build.finalName}.jar
</JAR_FILE>
</buildArgs>
...
...
src/main/java/com/egolm/shop/api/OrderController.java
View file @
7493a769
...
...
@@ -208,7 +208,7 @@ public class OrderController {
public
String
paySuccess
(
String
sSalesOrderID
,
BigDecimal
nPayAmount
,
String
sOpenID
,
String
sTransTraceNO
,
String
sOutTradeNO
,
String
PayTypeID
)
{
try
{
String
[]
ary
=
sOutTradeNO
.
split
(
"_"
,
2
);
List
<
Map
<
String
,
Object
>>
result
=
orderService
.
paySuccess
(
ary
[
0
],
nPayAmount
,
sOpenID
,
sTransTraceNO
,
new
Date
(),
PayTypeID
);
List
<
Map
<
String
,
Object
>>
result
=
orderService
.
paySuccess
(
ary
[
0
],
nPayAmount
,
sOpenID
,
sTransTraceNO
,
new
Date
(),
PayTypeID
,
""
);
return
Rjx
.
jsonOk
().
set
(
"list"
,
result
).
toJson
();
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
...
...
src/main/java/com/egolm/shop/api/PayNotifyController.java
View file @
7493a769
...
...
@@ -14,6 +14,7 @@ import org.json.XML;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.web.bind.annotation.RequestBody
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestMethod
;
...
...
@@ -21,6 +22,7 @@ import org.springframework.web.bind.annotation.RestController;
import
com.alibaba.fastjson.JSONObject
;
import
com.egolm.common.DateUtil
;
import
com.egolm.common.FileUtil
;
import
com.egolm.common.GsonUtil
;
import
com.egolm.common.HttpsUtil
;
import
com.egolm.common.StringUtil
;
...
...
@@ -44,6 +46,9 @@ public class PayNotifyController {
@Autowired
private
OrderService
orderService
;
@Value
(
"${pay.callback.path}"
)
private
String
callBackFilePath
;
@ApiIgnore
@ApiOperation
(
"支付回调通知接口"
)
@RequestMapping
(
value
=
"/callback"
,
method
=
RequestMethod
.
POST
)
...
...
@@ -62,9 +67,9 @@ public class PayNotifyController {
String
xmlMsg
=
StringUtil
.
inputStream2String
(
in
);
logger
.
info
(
"从egoPay中接收到支付回调信息 {}"
,
xmlMsg
);
postData
=
(
WxPayResponse
)
xs
.
fromXML
(
xmlMsg
);
List
<
Map
<
String
,
Object
>>
returnMap
=
orderService
.
payCallback
(
postData
);
postData
=
(
WxPayResponse
)
xs
.
fromXML
(
xmlMsg
);
List
<
Map
<
String
,
Object
>>
returnMap
=
orderService
.
payCallback
(
postData
,
xmlMsg
,
callBackFilePath
);
logger
.
info
(
"从egoPay中接收到支付信息结果 {}"
,
GsonUtil
.
toJson
(
returnMap
));
}
catch
(
Exception
e
)
{
...
...
@@ -79,7 +84,7 @@ public class PayNotifyController {
public
Object
mepayCallback
(
@RequestBody
String
req
,
HttpServletResponse
resp
)
{
logger
.
info
(
"从egoPay中接收到微企付回调通知接口: "
+
req
);
List
<
Map
<
String
,
Object
>>
returnMap
=
orderService
.
mePayCallback
(
req
);
List
<
Map
<
String
,
Object
>>
returnMap
=
orderService
.
mePayCallback
(
req
,
callBackFilePath
);
logger
.
info
(
"从egoPay中接收处理微企付回调信息结果 {}"
,
GsonUtil
.
toJson
(
returnMap
));
return
"success"
;
...
...
@@ -90,7 +95,7 @@ public class PayNotifyController {
@RequestMapping
(
value
=
"/mybankCallback"
,
method
=
RequestMethod
.
POST
)
public
Object
mybankCallback
(
@RequestBody
String
req
,
HttpServletResponse
resp
)
{
logger
.
info
(
"从egoPay中接收网商银行回调通知接口 {}"
,
req
);
List
<
Map
<
String
,
Object
>>
returnMap
=
orderService
.
myBankCallback
(
req
);
List
<
Map
<
String
,
Object
>>
returnMap
=
orderService
.
myBankCallback
(
req
,
callBackFilePath
);
logger
.
info
(
"处理从egoPay中接收网商银行回调通知结果 {}"
,
GsonUtil
.
toJson
(
returnMap
));
return
"success"
;
...
...
src/main/java/com/egolm/shop/api/service/OrderService.java
View file @
7493a769
...
...
@@ -22,7 +22,7 @@ public interface OrderService {
public
String
getOrderDetail
(
String
salesOrderId
,
String
agentID
);
public
List
<
Map
<
String
,
Object
>>
paySuccess
(
String
sOutTradeNO
,
BigDecimal
nPayAmount
,
String
sOpenID
,
String
sTransTraceNO
,
Date
dPayDateTime
,
String
PayTypeID
);
public
List
<
Map
<
String
,
Object
>>
paySuccess
(
String
sOutTradeNO
,
BigDecimal
nPayAmount
,
String
sOpenID
,
String
sTransTraceNO
,
Date
dPayDateTime
,
String
PayTypeID
,
String
callBackFilePath
);
public
String
getSubOrderDetail
(
String
subOrderID
,
String
agentID
);
...
...
@@ -46,9 +46,9 @@ public interface OrderService {
public
List
<
Map
<
String
,
Object
>>
createSettlePay
(
String
settleNO
,
String
payTypeID
,
String
payType
,
String
payAmount
,
String
payCardNO
)
;
public
List
<
Map
<
String
,
Object
>>
payCallback
(
WxPayResponse
postData
);
public
List
<
Map
<
String
,
Object
>>
payCallback
(
WxPayResponse
postData
,
String
xmlMsg
,
String
callBackFilePath
);
public
List
<
Map
<
String
,
Object
>>
mePayCallback
(
String
req
);
public
List
<
Map
<
String
,
Object
>>
mePayCallback
(
String
req
,
String
callBackFilePath
);
public
List
<
Map
<
String
,
Object
>>
myBankCallback
(
String
req
);
public
List
<
Map
<
String
,
Object
>>
myBankCallback
(
String
req
,
String
callBackFilePath
);
}
src/main/java/com/egolm/shop/api/service/impl/OrderServiceImpl.java
View file @
7493a769
This diff is collapsed.
Click to expand it.
src/main/resources/application.properties
View file @
7493a769
...
...
@@ -7,7 +7,7 @@ server.session.timeout=90000
server.tomcat.uri-encoding
=
utf-8
server.shop.name
=
shop
server.isSign
=
tru
e
server.isSign
=
fals
e
server.md5key
=
90f49d4bb0216c10816c7dec6bf28c89
spring.http.multipart.maxFileSize
=
5MB
...
...
@@ -58,7 +58,7 @@ spring.datasource.filters=stat,log4j
#读库
readonly.datasource.username
=
ERP
readonly.datasource.password
=
qiyang@2013
readonly.datasource.url
=
jdbc:sqlserver://10.10.0.22:1433;instanceName=SQLSERVER;DatabaseName=
SHOP
DB;allowMultiQueries=true
readonly.datasource.url
=
jdbc:sqlserver://10.10.0.22:1433;instanceName=SQLSERVER;DatabaseName=
B2B
DB;allowMultiQueries=true
readonly.datasource.driver-class-name
=
com.microsoft.sqlserver.jdbc.SQLServerDriver
#验证连接的有效性
readonly.datasource.test-while-idle
=
true
...
...
@@ -138,3 +138,4 @@ qiyewx.msg.redirect.appid=wxa573a87e45933b56
qiyewx.msg.timer
=
1/5 * * * * ?
pay.callback.path
=
D:/data/erp/callback/
\ No newline at end of file
src/main/resources/templates/redmine.html
View file @
7493a769
...
...
@@ -24,6 +24,8 @@
</head>
<body>
<div
id=
"app"
>
<el-divider
content-position=
"left"
>
V1.1.7.6 2024-5-6
</el-divider>
<p
class=
"title"
>
1.支付回调失败状态为99的,刚写文件,需求 #16796
</p>
<el-divider
content-position=
"left"
>
V1.1.7.5 2024-4-23
</el-divider>
<p
class=
"title"
>
1.增加接口签名验证及开关
</p>
<p
class=
"title"
>
2.需求 #16555、需求 #16563 需求 #16542,需求 #16595
</p>
...
...
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