Toggle navigation
Toggle navigation
This project
Loading...
Sign in
zyn
/
cjs-site
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
bruce
2019-05-21 16:46:17 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
7fc85ce0fdb005936206dda5e4fbd393d9d65fe1
7fc85ce0
1 parent
089d6419
仓管费
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
10 deletions
src/main/java/com/cjs/site/biz/user/pick/PickPayBiz.java
src/main/java/com/cjs/site/model/union/CreateQrCode.java
src/main/resources/mybatis/user/pick/out-prop-apply-pay-mapper.xml
src/main/java/com/cjs/site/biz/user/pick/PickPayBiz.java
View file @
7fc85ce
...
...
@@ -57,7 +57,6 @@ public class PickPayBiz {
// multiply(new BigDecimal(pickTotal)).add(new BigDecimal("6"));
BigDecimal
totalAmount
=
new
BigDecimal
(
"0.01"
);
//调试接口代码写死
result
.
put
(
"totalAmount"
,
totalAmount
);
String
pickNo
=
pickBiz
.
createPickNo
();
try
{
CreateQrCode
createQrCode
=
new
CreateQrCode
();
createQrCode
.
setQrCodeId
(
UnionPayUtil
.
getQrCodeId
());
...
...
@@ -67,7 +66,6 @@ public class PickPayBiz {
createQrCode
.
setBillDate
(
DateUtil
.
getNow
(
DateEnum
.
DATE
));
//此处拼接提货信息
OutpropApplyPickInfo
pickInfo
=
(
OutpropApplyPickInfo
)
session
.
getAttribute
(
"pickInfo"
);
pickInfo
.
setPickNo
(
pickNo
);
createQrCode
.
setSrcReserve
(
JsonUtil
.
toJsonRemoveNull
(
pickInfo
));
@SuppressWarnings
(
"unchecked"
)
Map
<
String
,
String
>
mapTypes
=
JsonUtil
.
fromJson
(
JsonUtil
.
toJson
(
createQrCode
),
Map
.
class
);
...
...
@@ -75,7 +73,7 @@ public class PickPayBiz {
UnionResponse
response
=
JsonUtil
.
fromJson
(
json
,
UnionResponse
.
class
);
if
(
response
!=
null
&&
response
.
getErrCode
().
equals
(
UnionConstants
.
SUCCESS_CODE
))
{
result
.
put
(
"qrCode"
,
UnionPayUtil
.
createQrCode
(
createQrCode
.
getQrCodeId
()));
insertPickPay
(
userId
,
createQrCode
.
getBillNo
(),
pickNo
,
createQrCode
.
getSrcReserve
());
insertPickPay
(
userId
,
createQrCode
.
getBillNo
(),
createQrCode
.
getSrcReserve
());
}
else
{
result
.
put
(
"code"
,
false
);
result
.
put
(
"msg"
,
response
.
getErrMsg
());
...
...
@@ -118,13 +116,12 @@ public class PickPayBiz {
return
false
;
}
private
void
insertPickPay
(
String
clientId
,
String
tradeNo
,
String
applyNo
,
String
extInfo
)
{
private
void
insertPickPay
(
String
clientId
,
String
tradeNo
,
String
extInfo
)
{
OutpropApplyPayInfo
insert
=
new
OutpropApplyPayInfo
();
insert
.
setCreatedAt
(
DateUtil
.
getNow
());
insert
.
setClientId
(
clientId
);
insert
.
setStatus
(
"1"
);
insert
.
setTradeNo
(
tradeNo
);
insert
.
setApplyNo
(
applyNo
);
insert
.
setExtInfo
(
extInfo
);
outpropApplyPayDao
.
insert
(
insert
);
}
...
...
src/main/java/com/cjs/site/model/union/CreateQrCode.java
View file @
7fc85ce
...
...
@@ -23,7 +23,7 @@ public class CreateQrCode implements Serializable {
private
String
totalAmount
;
private
String
qrCodeId
;
private
String
returnUrl
=
"https://www.zhao.com/login"
;
private
String
notifyUrl
=
"http://192.168.10.106/
notify.do
"
;
private
String
notifyUrl
=
"http://192.168.10.106/
/pick/pay/notify
"
;
public
String
getMsgSrc
()
{
return
msgSrc
;
...
...
src/main/resources/mybatis/user/pick/out-prop-apply-pay-mapper.xml
View file @
7fc85ce
...
...
@@ -7,20 +7,20 @@
<id
property=
"tradeNo"
column=
"TRADE_NO"
/>
<result
property=
"createdAt"
column=
"CREATED_AT"
/>
<result
property=
"updatedAt"
column=
"UPDATED_AT"
/>
<result
property=
"
applyNo"
column=
"APPLY_NO
"
/>
<result
property=
"
clientId"
column=
"CLIENT_ID
"
/>
<result
property=
"payAt"
column=
"PAY_AT"
/>
<result
property=
"status"
column=
"STATUS"
/>
<result
property=
"extInfo"
column=
"EXT_INFO"
/>
</resultMap>
<sql
id=
"base_field"
>
TRADE_NO,CREATED_AT,UPDATED_AT,
APPLY_NO,PAY_AT,STATUS,EXT_INFO
TRADE_NO,CREATED_AT,UPDATED_AT,
PAY_AT,STATUS,EXT_INFO,CLIENT_ID
</sql>
<insert
id=
"insert"
parameterType=
"OutpropApplyPayInfo"
>
INSERT INTO HS_ASSET.OUTPROPAPPLY_PAY (TRADE_NO,CREATED_AT,UPDATED_AT,
APPLY_NO,PAY_AT,STATUS,EXT_INFO
)
INSERT INTO HS_ASSET.OUTPROPAPPLY_PAY (TRADE_NO,CREATED_AT,UPDATED_AT,
PAY_AT,STATUS,EXT_INFO,CLIENT_ID
)
VALUES (#{tradeNo, jdbcType=VARCHAR}, #{createdAt, jdbcType=VARCHAR}, #{updatedAt, jdbcType=VARCHAR},
#{
applyNo, jdbcType=VARCHAR}, #{payAt, jdbcType=VARCHAR}, #{status, jdbcType=VARCHAR}, #{extInfo
, jdbcType=VARCHAR})
#{
payAt, jdbcType=VARCHAR}, #{status, jdbcType=VARCHAR}, #{extInfo, jdbcType=VARCHAR}, #{clientId
, jdbcType=VARCHAR})
</insert>
<select
id=
"selectByTradeNo"
parameterType=
"java.lang.String"
resultMap=
"BaseMap"
>
...
...
Please
register
or
login
to post a comment