-
-
Notifications
You must be signed in to change notification settings - Fork 8.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
e8a9d00
commit 9317366
Showing
5 changed files
with
239 additions
and
49 deletions.
There are no files selected for viewing
112 changes: 112 additions & 0 deletions
112
...ain/java/com/github/binarywang/wxpay/bean/request/WxPaySendMiniProgramRedpackRequest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,112 @@ | ||
package com.github.binarywang.wxpay.bean.request; | ||
|
||
import com.thoughtworks.xstream.annotations.XStreamAlias; | ||
import lombok.*; | ||
import lombok.experimental.Accessors; | ||
|
||
/** | ||
* 发送小程序红包请求参数对象. | ||
* | ||
* @author <a href="https://github.com/binarywang">Binary Wang</a> | ||
*/ | ||
@Data | ||
@EqualsAndHashCode(callSuper = true) | ||
@NoArgsConstructor | ||
@AllArgsConstructor | ||
@Builder | ||
@XStreamAlias("xml") | ||
@Accessors(chain = true) | ||
public class WxPaySendMiniProgramRedpackRequest extends BaseWxPayRequest { | ||
private static final long serialVersionUID = -2035425086824987567L; | ||
|
||
@Override | ||
protected String[] getIgnoredParamsForSign() { | ||
return new String[]{"sign_type", "sub_appid"}; | ||
} | ||
|
||
/** | ||
* mch_billno. | ||
* 商户订单号(每个订单号必须唯一) | ||
* 组成:mch_id+yyyymmdd+10位一天内不能重复的数字。 接口根据商户订单号支持重入,如出现超时可再调用。 | ||
*/ | ||
@XStreamAlias("mch_billno") | ||
private String mchBillNo; | ||
|
||
/** | ||
* send_name. | ||
* 商户名称 | ||
* 红包发送者名称 | ||
*/ | ||
@XStreamAlias("send_name") | ||
private String sendName; | ||
|
||
/** | ||
* re_openid. | ||
* 接受红包的用户 用户在wxappid下的openid | ||
*/ | ||
@XStreamAlias("re_openid") | ||
private String reOpenid; | ||
|
||
/** | ||
* total_amount. | ||
* 红包总额 | ||
*/ | ||
@XStreamAlias("total_amount") | ||
private Integer totalAmount; | ||
|
||
/** | ||
* total_num | ||
* 红包发放总人数 | ||
*/ | ||
@XStreamAlias("total_num") | ||
private Integer totalNum; | ||
|
||
/** | ||
* wishing. | ||
* 红包祝福语 | ||
*/ | ||
@XStreamAlias("wishing") | ||
private String wishing; | ||
|
||
/** | ||
* act_name. | ||
* 活动名称 | ||
*/ | ||
@XStreamAlias("act_name") | ||
private String actName; | ||
|
||
/** | ||
* remark. | ||
* 备注 | ||
*/ | ||
@XStreamAlias("remark") | ||
private String remark; | ||
|
||
/** | ||
* 通知用户形式 . | ||
* 通过JSAPI方式领取红包,小程序红包固定传MINI_PROGRAM_JSAPI | ||
*/ | ||
@XStreamAlias("notify_way") | ||
private String notifyWay = "MINI_PROGRAM_JSAPI"; | ||
|
||
/** | ||
* <pre> | ||
* 发放红包使用场景,红包金额大于200时必传 | ||
* PRODUCT_1:商品促销 | ||
* PRODUCT_2:抽奖 | ||
* PRODUCT_3:虚拟物品兑奖 | ||
* PRODUCT_4:企业内部福利 | ||
* PRODUCT_5:渠道分润 | ||
* PRODUCT_6:保险回馈 | ||
* PRODUCT_7:彩票派奖 | ||
* PRODUCT_8:税务刮奖 | ||
* </pre> | ||
*/ | ||
@XStreamAlias("scene_id") | ||
private String sceneId; | ||
|
||
@Override | ||
protected void checkConstraints() { | ||
|
||
} | ||
} |
56 changes: 56 additions & 0 deletions
56
.../main/java/com/github/binarywang/wxpay/bean/result/WxPaySendMiniProgramRedpackResult.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
package com.github.binarywang.wxpay.bean.result; | ||
|
||
import com.thoughtworks.xstream.annotations.XStreamAlias; | ||
import lombok.Data; | ||
import lombok.EqualsAndHashCode; | ||
import lombok.NoArgsConstructor; | ||
|
||
import java.io.Serializable; | ||
|
||
/** | ||
* 发送小程序红包的返回结果 | ||
* | ||
* @author <a href="https://github.com/binarywang">Binary Wang</a> | ||
*/ | ||
@Data | ||
@EqualsAndHashCode(callSuper = true) | ||
@NoArgsConstructor | ||
@XStreamAlias("xml") | ||
public class WxPaySendMiniProgramRedpackResult extends BaseWxPayResult implements Serializable { | ||
/** | ||
* 商户订单号. | ||
*/ | ||
@XStreamAlias("mch_billno") | ||
private String mchBillNo; | ||
|
||
/** | ||
* 公众账号appid. | ||
*/ | ||
@XStreamAlias("wxappid") | ||
private String wxAppid; | ||
|
||
/** | ||
* 用户openid. | ||
*/ | ||
@XStreamAlias("re_openid") | ||
private String reOpenid; | ||
|
||
/** | ||
* 付款金额. | ||
*/ | ||
@XStreamAlias("total_amount") | ||
private int totalAmount; | ||
|
||
/** | ||
* 返回jaspi的入参package的值. | ||
*/ | ||
@XStreamAlias("package") | ||
private String packageName; | ||
|
||
/** | ||
* 微信单号. | ||
*/ | ||
@XStreamAlias("send_listid") | ||
private String sendListId; | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters