Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
caosy
/
fun-golf-service
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
1
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
70dcffcd
authored
Apr 02, 2019
by
zhangchen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1.活动字段添加
parent
0c03b26a
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
39 additions
and
7 deletions
src/main/java/com/ctrip/fun/golf/domain/payment/WeiXinAtcion.java
src/main/java/com/ctrip/fun/golf/domain/product/BuyVoucherActivity.java
src/main/java/com/ctrip/fun/golf/service/payment/CommuneNotifyService.java
src/main/java/com/ctrip/fun/golf/domain/payment/WeiXinAtcion.java
View file @
70dcffcd
...
@@ -199,19 +199,19 @@ public class WeiXinAtcion {
...
@@ -199,19 +199,19 @@ public class WeiXinAtcion {
}
}
public
static
Map
<
String
,
String
>
weixinPlay1
(
String
openId
,
BigDecimal
amount
,
Long
orderNo
)
throws
UnsupportedEncodingException
,
DocumentException
{
public
static
Map
<
String
,
String
>
weixinPlay1
(
String
openId
,
String
amount
,
Long
orderNo
,
String
actName
,
String
sendName
,
String
wishing
)
throws
UnsupportedEncodingException
,
DocumentException
{
SortedMap
<
Object
,
Object
>
paymentPo
=
new
TreeMap
<
Object
,
Object
>();
SortedMap
<
Object
,
Object
>
paymentPo
=
new
TreeMap
<
Object
,
Object
>();
paymentPo
.
put
(
"mch_billno"
,
orderNo
.
toString
());
paymentPo
.
put
(
"mch_billno"
,
orderNo
.
toString
());
paymentPo
.
put
(
"mch_id"
,
Configure
.
getMch_id
());
paymentPo
.
put
(
"mch_id"
,
Configure
.
getMch_id
());
paymentPo
.
put
(
"wxappid"
,
Configure
.
getAppID
());
paymentPo
.
put
(
"wxappid"
,
Configure
.
getAppID
());
paymentPo
.
put
(
"send_name"
,
"爱玩高尔夫"
);
paymentPo
.
put
(
"send_name"
,
sendName
);
paymentPo
.
put
(
"re_openid"
,
openId
);
paymentPo
.
put
(
"re_openid"
,
openId
);
paymentPo
.
put
(
"total_amount"
,
amount
.
multiply
(
new
BigDecimal
(
100
)).
toString
().
substring
(
0
,
amount
.
multiply
(
new
BigDecimal
(
100
)).
toString
().
length
()-
3
)
);
paymentPo
.
put
(
"total_amount"
,
amount
);
paymentPo
.
put
(
"total_num"
,
"1"
);
paymentPo
.
put
(
"total_num"
,
"1"
);
paymentPo
.
put
(
"wishing"
,
"恭喜发财"
);
paymentPo
.
put
(
"wishing"
,
wishing
);
paymentPo
.
put
(
"client_ip"
,
"127.0.0.1"
);
paymentPo
.
put
(
"client_ip"
,
"127.0.0.1"
);
paymentPo
.
put
(
"act_name"
,
"新年红包"
);
paymentPo
.
put
(
"act_name"
,
actName
);
paymentPo
.
put
(
"remark"
,
"
新年
红包"
);
paymentPo
.
put
(
"remark"
,
"
活动
红包"
);
paymentPo
.
put
(
"scene_id"
,
"PRODUCT_1"
);
paymentPo
.
put
(
"scene_id"
,
"PRODUCT_1"
);
paymentPo
.
put
(
"nonce_str"
,
WXUtil
.
generate
());
paymentPo
.
put
(
"nonce_str"
,
WXUtil
.
generate
());
paymentPo
.
put
(
"sign"
,
WXUtil
.
createSign_ChooseWXPay
(
"UTF-8"
,
paymentPo
,
Configure
.
getKey
()));
paymentPo
.
put
(
"sign"
,
WXUtil
.
createSign_ChooseWXPay
(
"UTF-8"
,
paymentPo
,
Configure
.
getKey
()));
...
...
src/main/java/com/ctrip/fun/golf/domain/product/BuyVoucherActivity.java
View file @
70dcffcd
...
@@ -44,6 +44,9 @@ public class BuyVoucherActivity implements java.io.Serializable {
...
@@ -44,6 +44,9 @@ public class BuyVoucherActivity implements java.io.Serializable {
private
Date
DataChange_LastTime
;
//最近修改时间
private
Date
DataChange_LastTime
;
//最近修改时间
private
Integer
isSendRedPacket
;
//是否发放红包:0 不发放 1发放
private
Integer
isSendRedPacket
;
//是否发放红包:0 不发放 1发放
private
BigDecimal
redPacketPrice
;
//红包金额
private
BigDecimal
redPacketPrice
;
//红包金额
private
String
sendName
;
//发送方名称
private
String
actName
;
//活动名称
private
String
wishing
;
//祝福语
...
@@ -208,5 +211,32 @@ public class BuyVoucherActivity implements java.io.Serializable {
...
@@ -208,5 +211,32 @@ public class BuyVoucherActivity implements java.io.Serializable {
this
.
redPacketPrice
=
redPacketPrice
;
this
.
redPacketPrice
=
redPacketPrice
;
}
}
@Column
(
name
=
"sendName"
)
public
String
getSendName
()
{
return
sendName
;
}
public
void
setSendName
(
String
sendName
)
{
this
.
sendName
=
sendName
;
}
@Column
(
name
=
"actName"
)
public
String
getActName
()
{
return
actName
;
}
public
void
setActName
(
String
actName
)
{
this
.
actName
=
actName
;
}
@Column
(
name
=
"wishing"
)
public
String
getWishing
()
{
return
wishing
;
}
public
void
setWishing
(
String
wishing
)
{
this
.
wishing
=
wishing
;
}
}
}
src/main/java/com/ctrip/fun/golf/service/payment/CommuneNotifyService.java
View file @
70dcffcd
...
@@ -113,7 +113,9 @@ public class CommuneNotifyService extends AbstractNotifyService {
...
@@ -113,7 +113,9 @@ public class CommuneNotifyService extends AbstractNotifyService {
//给推荐人发现金红包
//给推荐人发现金红包
if
(
buyVoucherActivity
.
getIsSendRedPacket
()
!=
null
&&
buyVoucherActivity
.
getIsSendRedPacket
()
==
1
&&
!
StringUtils
.
isEmpty
(
communeOrderItem
.
getRecommendUid
())){
if
(
buyVoucherActivity
.
getIsSendRedPacket
()
!=
null
&&
buyVoucherActivity
.
getIsSendRedPacket
()
==
1
&&
!
StringUtils
.
isEmpty
(
communeOrderItem
.
getRecommendUid
())){
UserExt
user
=
userExtDao
.
getByUid
(
communeOrderItem
.
getRecommendUid
());
UserExt
user
=
userExtDao
.
getByUid
(
communeOrderItem
.
getRecommendUid
());
WeiXinAtcion
.
weixinPlay1
(
user
.
getMiniAppOpenId
(),
buyVoucherActivity
.
getRedPacketPrice
(),
order
.
getOrderNo
());
BigDecimal
amount
=
buyVoucherActivity
.
getRedPacketPrice
();
amount
=
amount
.
multiply
(
new
BigDecimal
(
100
));
WeiXinAtcion
.
weixinPlay1
(
user
.
getMiniAppOpenId
(),
amount
.
toString
().
substring
(
0
,
amount
.
toString
().
length
()
-
3
),
order
.
getOrderNo
(),
buyVoucherActivity
.
getSendName
(),
buyVoucherActivity
.
getActName
(),
buyVoucherActivity
.
getWishing
());
}
}
}
}
}
}
...
...
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