当面付进件修改1
This commit is contained in:
@@ -101,6 +101,7 @@ public class EntryManager {
|
|||||||
entryRespDto.setAlipayOrderId(respDto.getEntryId());
|
entryRespDto.setAlipayOrderId(respDto.getEntryId());
|
||||||
entryRespDto.setAlipayStatus(respDto.getStatus());
|
entryRespDto.setAlipayStatus(respDto.getStatus());
|
||||||
entryRespDto.setAlipayErrorMsg(respDto.getErrorMsg());
|
entryRespDto.setAlipayErrorMsg(respDto.getErrorMsg());
|
||||||
|
entryRespDto.setAlipayAuthInfo(respDto.getAlipayAuthInfo());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return entryRespDto;
|
return entryRespDto;
|
||||||
|
|||||||
@@ -33,6 +33,11 @@ public class EntryRespDto {
|
|||||||
*/
|
*/
|
||||||
private String alipayOrderId;
|
private String alipayOrderId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 支付宝授信息
|
||||||
|
*/
|
||||||
|
private String alipayAuthInfo;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 支付宝状态
|
* 支付宝状态
|
||||||
* {@link com.czg.PayCst.EntryStatus}
|
* {@link com.czg.PayCst.EntryStatus}
|
||||||
|
|||||||
@@ -16,6 +16,11 @@ public class EntryThirdRespDto {
|
|||||||
*/
|
*/
|
||||||
private String entryId;
|
private String entryId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 支付宝授信息
|
||||||
|
*/
|
||||||
|
private String alipayAuthInfo;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 平台
|
* 平台
|
||||||
*/
|
*/
|
||||||
|
|||||||
@@ -103,6 +103,7 @@ public class AlipayIsvEntryManager {
|
|||||||
.setPlatform(PayCst.Platform.ALIPAY);
|
.setPlatform(PayCst.Platform.ALIPAY);
|
||||||
try {
|
try {
|
||||||
String batchNo = createRequest(reqDto);
|
String batchNo = createRequest(reqDto);
|
||||||
|
respDto.setEntryId(batchNo);
|
||||||
|
|
||||||
AlipayOpenAgentFacetofaceSignModel signModel = buildFaceToFaceModel(reqDto, batchNo);
|
AlipayOpenAgentFacetofaceSignModel signModel = buildFaceToFaceModel(reqDto, batchNo);
|
||||||
File businessLicensePic = UploadFileUtil.getFileByUrl(reqDto.getBusinessLicenceInfo().getLicensePic().getUrl());
|
File businessLicensePic = UploadFileUtil.getFileByUrl(reqDto.getBusinessLicenceInfo().getLicensePic().getUrl());
|
||||||
@@ -115,8 +116,8 @@ public class AlipayIsvEntryManager {
|
|||||||
log.info("支付宝开启代商户签约: 响应={}", JSONObject.toJSONString(response));
|
log.info("支付宝开启代商户签约: 响应={}", JSONObject.toJSONString(response));
|
||||||
|
|
||||||
try {
|
try {
|
||||||
String orderNo = confirmRequest(batchNo);
|
String authInfo = confirmRequest(batchNo);
|
||||||
respDto.setEntryId(orderNo);
|
respDto.setAlipayAuthInfo(authInfo);
|
||||||
respDto.setStatus(PayCst.EntryStatus.INIT);
|
respDto.setStatus(PayCst.EntryStatus.INIT);
|
||||||
respDto.setErrorMsg("");
|
respDto.setErrorMsg("");
|
||||||
return respDto;
|
return respDto;
|
||||||
@@ -180,15 +181,15 @@ public class AlipayIsvEntryManager {
|
|||||||
public static String confirmRequest(String batchNo) {
|
public static String confirmRequest(String batchNo) {
|
||||||
AlipayClient.setApiClient(null);
|
AlipayClient.setApiClient(null);
|
||||||
// 构造请求参数以调用接口
|
// 构造请求参数以调用接口
|
||||||
AlipayOpenAgentCommonsignApi api = new AlipayOpenAgentCommonsignApi();
|
AlipayOpenAgentApi api = new AlipayOpenAgentApi();
|
||||||
AlipayOpenAgentCommonsignConfirmModel data = new AlipayOpenAgentCommonsignConfirmModel();
|
AlipayOpenAgentConfirmModel data = new AlipayOpenAgentConfirmModel();
|
||||||
|
|
||||||
// 设置ISV 代商户操作事务编号
|
// 设置ISV 代商户操作事务编号
|
||||||
data.setBatchNo(batchNo);
|
data.setBatchNo(batchNo);
|
||||||
try {
|
try {
|
||||||
AlipayOpenAgentCommonsignConfirmResponseModel response = api.confirm(data);
|
AlipayOpenAgentConfirmResponseModel response = api.confirm(data);
|
||||||
log.info("支付宝开启代商户签约,确认事务: 响应={}", response);
|
log.info("支付宝开启代商户签约,确认事务: 响应={}", response);
|
||||||
return response.getOrderNo();
|
return JSONObject.toJSONString(response);
|
||||||
} catch (ApiException e) {
|
} catch (ApiException e) {
|
||||||
String body = e.getResponseBody();
|
String body = e.getResponseBody();
|
||||||
log.error("支付宝开启代商户签约,确认事务异常: {}", body);
|
log.error("支付宝开启代商户签约,确认事务异常: {}", body);
|
||||||
|
|||||||
Reference in New Issue
Block a user