快捷充值
parent
db8a0de0ef
commit
c991eaf12d
|
|
@ -3,10 +3,7 @@ package com.czcb.scfs.api.service.v1.pay;
|
|||
import com.czcb.scfs.api.core.ApiClient;
|
||||
import com.czcb.scfs.api.core.http.HttpHeaders;
|
||||
import com.czcb.scfs.api.core.http.HttpResponse;
|
||||
import com.czcb.scfs.api.service.v1.pay.model.MerWithdrawCheckRequest;
|
||||
import com.czcb.scfs.api.service.v1.pay.model.MerWithdrawCheckResponse;
|
||||
import com.czcb.scfs.api.service.v1.pay.model.MerWithdrawRequest;
|
||||
import com.czcb.scfs.api.service.v1.pay.model.MerWithdrawResponse;
|
||||
import com.czcb.scfs.api.service.v1.pay.model.*;
|
||||
|
||||
import static com.czcb.scfs.api.core.Constants.API_VERSION;
|
||||
import static com.czcb.scfs.api.core.Constants.V_1;
|
||||
|
|
@ -49,4 +46,18 @@ public class PayService {
|
|||
HttpResponse<MerWithdrawCheckResponse> httpResponse = apiClient.post(url, headers, request.toJsonRequest(), MerWithdrawCheckResponse.class);
|
||||
return httpResponse.getServiceResponse();
|
||||
}
|
||||
|
||||
/**
|
||||
* 快捷充值
|
||||
*
|
||||
* @param request MerDepositRequest
|
||||
* @return MerDepositResponse
|
||||
*/
|
||||
public MerDepositResponse withdrawCheck(MerDepositRequest request) {
|
||||
String url = "/merTrade/mer_deposit";
|
||||
HttpHeaders headers = new HttpHeaders();
|
||||
headers.addHeader(API_VERSION, V_1);
|
||||
HttpResponse<MerDepositResponse> httpResponse = apiClient.post(url, headers, request.toJsonRequest(), MerDepositResponse.class);
|
||||
return httpResponse.getServiceResponse();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,104 @@
|
|||
package com.czcb.scfs.api.service.v1.pay.model;
|
||||
|
||||
import com.czcb.scfs.api.core.ApiRequest;
|
||||
import com.czcb.scfs.api.service.TransType;
|
||||
import com.google.gson.annotations.SerializedName;
|
||||
import lombok.Data;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
|
||||
/**
|
||||
* 快捷充值
|
||||
*
|
||||
* @author wangwei
|
||||
* @since 2.0.0
|
||||
*/
|
||||
@Data
|
||||
@Accessors(chain = true)
|
||||
@TransType("100020")
|
||||
public class MerDepositRequest implements ApiRequest {
|
||||
/**
|
||||
* 渠道编号
|
||||
*/
|
||||
@SerializedName("channel_no")
|
||||
private String channelNo;
|
||||
|
||||
/**
|
||||
* 应用编号
|
||||
*/
|
||||
@SerializedName("app_no")
|
||||
private String appNo;
|
||||
|
||||
/**
|
||||
* 流水号
|
||||
*/
|
||||
@SerializedName("serial_no")
|
||||
private String serialNo;
|
||||
|
||||
/**
|
||||
* 收款账户账号
|
||||
*/
|
||||
@SerializedName("account_no")
|
||||
private String accountNo;
|
||||
|
||||
/**
|
||||
* 收款账户户名
|
||||
*/
|
||||
@SerializedName("account_name")
|
||||
private String accountName;
|
||||
|
||||
/**
|
||||
* 币种
|
||||
*/
|
||||
@SerializedName("currency")
|
||||
private String currency;
|
||||
|
||||
/**
|
||||
* 个人为银行卡号,不支持企业线上充值
|
||||
*/
|
||||
@SerializedName("primary_account")
|
||||
private String primaryAccount;
|
||||
|
||||
/**
|
||||
* 充值金额
|
||||
*/
|
||||
@SerializedName("amount")
|
||||
private BigDecimal amount;
|
||||
|
||||
/**
|
||||
* 交易码=功能号(trans_type)
|
||||
*/
|
||||
@SerializedName("trade_no")
|
||||
private String tradeNo;
|
||||
|
||||
/**
|
||||
* 验证码,短信验证码
|
||||
*/
|
||||
@SerializedName("verify_code")
|
||||
private String verifyCode;
|
||||
|
||||
/**
|
||||
* 摘要
|
||||
*/
|
||||
@SerializedName("trans_summary")
|
||||
private String transSummary;
|
||||
|
||||
/**
|
||||
* 回调地址
|
||||
*/
|
||||
@SerializedName("receive_url")
|
||||
private String receiveUrl;
|
||||
|
||||
/**
|
||||
* 操作日期
|
||||
*/
|
||||
@SerializedName("original_serialno")
|
||||
private String transDate;
|
||||
|
||||
/**
|
||||
* 操作时间
|
||||
*/
|
||||
@SerializedName("trans_tradetime")
|
||||
private String transTradeTime;
|
||||
}
|
||||
|
|
@ -0,0 +1,75 @@
|
|||
package com.czcb.scfs.api.service.v1.pay.model;
|
||||
|
||||
import com.czcb.scfs.api.core.ApiResponse;
|
||||
import com.google.gson.annotations.SerializedName;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
|
||||
/**
|
||||
* 快捷充值
|
||||
*
|
||||
* @author wangwei
|
||||
* @since 2.0.0
|
||||
*/
|
||||
@Data
|
||||
public class MerDepositResponse implements ApiResponse {
|
||||
/**
|
||||
* 000000:表示成功
|
||||
*/
|
||||
@SerializedName("recode")
|
||||
private String recode;
|
||||
|
||||
/**
|
||||
* 结果信息
|
||||
*/
|
||||
@SerializedName("recode_Info")
|
||||
private String recodeInfo;
|
||||
|
||||
/**
|
||||
* 流水号
|
||||
*/
|
||||
@SerializedName("serial_no")
|
||||
private String serialNo;
|
||||
|
||||
/**
|
||||
* 账号
|
||||
*/
|
||||
@SerializedName("account_no")
|
||||
private String accountNo;
|
||||
|
||||
/**
|
||||
* 户名
|
||||
*/
|
||||
@SerializedName("account_name")
|
||||
private String accountName;
|
||||
|
||||
/**
|
||||
* 原交易码
|
||||
*/
|
||||
@SerializedName("original_tradeno")
|
||||
private String originalTradeNo;
|
||||
|
||||
/**
|
||||
* 原交易流水号
|
||||
*/
|
||||
@SerializedName("original_serialno")
|
||||
private String originalSerialNo;
|
||||
/**
|
||||
* 交易金额
|
||||
*/
|
||||
@SerializedName("trans_amount")
|
||||
private BigDecimal transAmount;
|
||||
|
||||
/**
|
||||
* 系统日期(YYYY-MM-DD)
|
||||
*/
|
||||
@SerializedName("sys_date")
|
||||
private String sysDate;
|
||||
|
||||
/**
|
||||
* 系统时间(YYYY-MM-DD hh:mm:ss)
|
||||
*/
|
||||
@SerializedName("recode_Info")
|
||||
private String sysTime;
|
||||
}
|
||||
Loading…
Reference in New Issue