发票匹配,发票来账明细查询
parent
7675c18b87
commit
6eb1330d00
|
|
@ -3,8 +3,7 @@ package com.czcb.scfs.service.accountant.invoice;
|
|||
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.service.accountant.invoice.model.InvoiceInfoSaveApiRequest;
|
||||
import com.czcb.scfs.service.accountant.invoice.model.InvoiceInfoSaveApiResponse;
|
||||
import com.czcb.scfs.service.accountant.invoice.model.*;
|
||||
|
||||
import static com.czcb.scfs.api.core.Constants.API_VERSION;
|
||||
import static com.czcb.scfs.api.core.Constants.V_2;
|
||||
|
|
@ -33,5 +32,25 @@ public class InvoiceService {
|
|||
HttpResponse<InvoiceInfoSaveApiResponse> httpResponse = apiClient.post(url, headers, request.toJsonRequest(), InvoiceInfoSaveApiResponse.class);
|
||||
return httpResponse.getServiceResponse();
|
||||
}
|
||||
/**
|
||||
* 232007-发票匹配
|
||||
*/
|
||||
public InvoiceSettleMatchApiResponse settleMatch(InvoiceSettleMatchApiRequest request) {
|
||||
String url = "/invoice/settle/match";
|
||||
HttpHeaders headers = new HttpHeaders();
|
||||
headers.addHeader(API_VERSION, V_2);
|
||||
HttpResponse<InvoiceSettleMatchApiResponse> httpResponse = apiClient.post(url, headers, request.toJsonRequest(), InvoiceSettleMatchApiResponse.class);
|
||||
return httpResponse.getServiceResponse();
|
||||
}
|
||||
/**
|
||||
* 232008-发票来账明细查询
|
||||
*/
|
||||
public InvoiceDepositQueryApiResponse invoiceDepositQuery(InvoiceDepositQueryApiRequest request) {
|
||||
String url = "/invoice/deposit/query";
|
||||
HttpHeaders headers = new HttpHeaders();
|
||||
headers.addHeader(API_VERSION, V_2);
|
||||
HttpResponse<InvoiceDepositQueryApiResponse> httpResponse = apiClient.post(url, headers, request.toJsonRequest(), InvoiceDepositQueryApiResponse.class);
|
||||
return httpResponse.getServiceResponse();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,85 @@
|
|||
package com.czcb.scfs.service.accountant.invoice.model;
|
||||
|
||||
import com.czcb.scfs.api.core.ApiRequest;
|
||||
import com.czcb.scfs.api.core.agrs.TransType;
|
||||
import com.google.gson.annotations.SerializedName;
|
||||
import lombok.Data;
|
||||
import lombok.experimental.Accessors;
|
||||
/**
|
||||
* <p>
|
||||
* 发票来账明细查询
|
||||
* </p>
|
||||
*
|
||||
* @author zzf
|
||||
* @since 2024-07-22
|
||||
*/
|
||||
@Data
|
||||
@Accessors(chain = true)
|
||||
@TransType("232008")
|
||||
public class InvoiceDepositQueryApiRequest implements ApiRequest {
|
||||
/**
|
||||
* 渠道编号
|
||||
*/
|
||||
@SerializedName("channel_no")
|
||||
private String channelNo;
|
||||
|
||||
/**
|
||||
* 应用编号
|
||||
*/
|
||||
@SerializedName("app_no")
|
||||
private String appNo;
|
||||
|
||||
/**
|
||||
* 流水号
|
||||
*/
|
||||
@SerializedName("serial_no")
|
||||
private String serialNo;
|
||||
|
||||
/**
|
||||
* 操作日期
|
||||
*/
|
||||
@SerializedName("trans_date")
|
||||
private String transDate;
|
||||
|
||||
/**
|
||||
* 操作时间
|
||||
*/
|
||||
@SerializedName("trans_tradetime")
|
||||
private String transTradeTime;
|
||||
/**
|
||||
* 发票编号
|
||||
*/
|
||||
@SerializedName("invoice_no")
|
||||
private String invoiceNo;
|
||||
|
||||
/**
|
||||
* 收款账户账号(入账账户)
|
||||
*/
|
||||
@SerializedName("account_no")
|
||||
private String accountNo;
|
||||
/**
|
||||
* 收款账户户名(入账账户)
|
||||
*/
|
||||
@SerializedName("account_name")
|
||||
private String accountName;
|
||||
/**
|
||||
* 付款账户账号
|
||||
*/
|
||||
@SerializedName("opp_account_no")
|
||||
private String oppAccountNo;
|
||||
/**
|
||||
* 付款账户户名
|
||||
*/
|
||||
@SerializedName("opp_account_name")
|
||||
private String oppAccountName;
|
||||
/**
|
||||
* 归集账户账号(待清算账户/可控电商A2)
|
||||
*/
|
||||
@SerializedName("settle_account_no")
|
||||
private String settleAccountNo;
|
||||
/**
|
||||
* 归集账户户名(待清算账户/可控电商A2)
|
||||
*/
|
||||
@SerializedName("settle_account_name")
|
||||
private String settleAccountName;
|
||||
}
|
||||
|
|
@ -0,0 +1,140 @@
|
|||
package com.czcb.scfs.service.accountant.invoice.model;
|
||||
|
||||
import com.czcb.scfs.api.core.ApiResponse;
|
||||
import com.google.gson.annotations.SerializedName;
|
||||
import lombok.Data;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
/**
|
||||
* <p>
|
||||
* 发票来账明细查询
|
||||
* </p>
|
||||
*
|
||||
* @author zzf
|
||||
* @since 2024-07-22
|
||||
*/
|
||||
@Data
|
||||
@Accessors(chain = true)
|
||||
public class InvoiceDepositQueryApiResponse implements ApiResponse {
|
||||
/**
|
||||
* 000000:表示成功
|
||||
*/
|
||||
@SerializedName("recode")
|
||||
private String recode;
|
||||
|
||||
/**
|
||||
* 结果信息
|
||||
*/
|
||||
@SerializedName("recode_info")
|
||||
private String recodeInfo;
|
||||
|
||||
/**
|
||||
* 系统流水号
|
||||
*/
|
||||
@SerializedName("sys_serial_no")
|
||||
private String sysSerialNo;
|
||||
|
||||
/**
|
||||
* 系统日期(YYYY-MM-DD)
|
||||
*/
|
||||
@SerializedName("sys_date")
|
||||
private String sysDate;
|
||||
|
||||
/**
|
||||
* 系统时间(YYYY-MM-DD hh:mm:ss)
|
||||
*/
|
||||
@SerializedName("sys_time")
|
||||
private String sysTime;
|
||||
|
||||
@SerializedName("data")
|
||||
private List<InvoiceDepositData> data;
|
||||
|
||||
@Data
|
||||
@Accessors(chain = true)
|
||||
public static class InvoiceDepositData implements Serializable {
|
||||
/**
|
||||
* 发票编号
|
||||
*/
|
||||
@SerializedName("invoice_no")
|
||||
private String invoiceNo;
|
||||
/**
|
||||
* 收款账户账号(入账账户)
|
||||
*/
|
||||
@SerializedName("account_no")
|
||||
private String accountNo;
|
||||
/**
|
||||
* 收款账户户名(入账账户)
|
||||
*/
|
||||
@SerializedName("account_name")
|
||||
private String accountName;
|
||||
/**
|
||||
* 付款账户账号
|
||||
*/
|
||||
@SerializedName("opp_account_no")
|
||||
private String oppAccountNo;
|
||||
/**
|
||||
* 付款账户户名
|
||||
*/
|
||||
@SerializedName("opp_account_name")
|
||||
private String oppAccountName;
|
||||
/**
|
||||
* 归集账户账号(待清算账户/可控电商A2)
|
||||
*/
|
||||
@SerializedName("settle_account_no")
|
||||
private String settleAccountNo;
|
||||
/**
|
||||
* 归集账户户名(待清算账户/可控电商A2)
|
||||
*/
|
||||
@SerializedName("settle_account_name")
|
||||
private String settleAccountName;
|
||||
/**
|
||||
* 来账流水号
|
||||
*/
|
||||
@SerializedName("deposit_serial_no")
|
||||
private String depositSerialNo;
|
||||
|
||||
/**
|
||||
* 来账金额
|
||||
*/
|
||||
@SerializedName("deposit_amount")
|
||||
private BigDecimal depositAmount;
|
||||
|
||||
/**
|
||||
* 结算金额(匹配金额)
|
||||
*/
|
||||
@SerializedName("settle_amount")
|
||||
private BigDecimal settleAmount;
|
||||
|
||||
/**
|
||||
* 匹配类型 1、自动匹配 2、人工匹配
|
||||
*/
|
||||
@SerializedName("match_type")
|
||||
private String matchType;
|
||||
|
||||
/**
|
||||
* 匹配状态 0、未匹配 1、匹配成功
|
||||
*/
|
||||
@SerializedName("match_status")
|
||||
private String matchStatus;
|
||||
|
||||
/**
|
||||
* 匹配时间
|
||||
*/
|
||||
@SerializedName("match_time")
|
||||
private Date matchTime;
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
@SerializedName("create_time")
|
||||
private Date createTime;
|
||||
/**
|
||||
* 更新时间
|
||||
*/
|
||||
@SerializedName("update_time")
|
||||
private Date updateTime;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,95 @@
|
|||
package com.czcb.scfs.service.accountant.invoice.model;
|
||||
|
||||
import com.czcb.scfs.api.core.ApiRequest;
|
||||
import com.czcb.scfs.api.core.agrs.TransType;
|
||||
import com.google.gson.annotations.SerializedName;
|
||||
import lombok.Data;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 发票匹配
|
||||
* </p>
|
||||
*
|
||||
* @author zzf
|
||||
* @since 2024-07-04
|
||||
*/
|
||||
@Data
|
||||
@Accessors(chain = true)
|
||||
@TransType("232007")
|
||||
public class InvoiceSettleMatchApiRequest implements ApiRequest {
|
||||
/**
|
||||
* 渠道编号
|
||||
*/
|
||||
@SerializedName("channel_no")
|
||||
private String channelNo;
|
||||
|
||||
/**
|
||||
* 应用编号
|
||||
*/
|
||||
@SerializedName("app_no")
|
||||
private String appNo;
|
||||
|
||||
/**
|
||||
* 流水号
|
||||
*/
|
||||
@SerializedName("serial_no")
|
||||
private String serialNo;
|
||||
|
||||
/**
|
||||
* 操作日期
|
||||
*/
|
||||
@SerializedName("trans_date")
|
||||
private String transDate;
|
||||
|
||||
/**
|
||||
* 操作时间
|
||||
*/
|
||||
@SerializedName("trans_tradetime")
|
||||
private String transTradeTime;
|
||||
/**
|
||||
* 来账流水号,结算金额数据集
|
||||
*/
|
||||
@SerializedName("data")
|
||||
private List<InvoiceSettleMatchApiReqData> data;
|
||||
@Data
|
||||
@Accessors(chain = true)
|
||||
private static class InvoiceSettleMatchApiReqData implements Serializable{
|
||||
/**
|
||||
* 来账流水号
|
||||
*/
|
||||
@SerializedName("deposit_serial_no")
|
||||
private String depositSerialNo;
|
||||
/**
|
||||
* 结算金额
|
||||
*/
|
||||
@SerializedName("match_amount")
|
||||
private BigDecimal matchAmount;
|
||||
}
|
||||
/**
|
||||
* 发票编号
|
||||
*/
|
||||
@SerializedName("invoice_no")
|
||||
private String invoiceNo;
|
||||
/**
|
||||
* 收款账户账号
|
||||
*/
|
||||
@SerializedName("account_no")
|
||||
private String accountNo;
|
||||
/**
|
||||
* 付款账户账号
|
||||
*/
|
||||
@SerializedName("opp_account_no")
|
||||
private String oppAccountNo;
|
||||
/**
|
||||
* 匹配类型
|
||||
* 1、自动匹配
|
||||
* 2、人工匹配
|
||||
*/
|
||||
@SerializedName("match_type")
|
||||
private String matchType;
|
||||
}
|
||||
|
|
@ -0,0 +1,72 @@
|
|||
package com.czcb.scfs.service.accountant.invoice.model;
|
||||
import com.czcb.scfs.api.core.ApiResponse;
|
||||
import com.google.gson.annotations.SerializedName;
|
||||
import lombok.Data;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 发票匹配出参
|
||||
* </p>
|
||||
*
|
||||
* @author zzf
|
||||
* @since 2024-07-04
|
||||
*/
|
||||
@Data
|
||||
@Accessors(chain = true)
|
||||
public class InvoiceSettleMatchApiResponse implements ApiResponse {
|
||||
/**
|
||||
* 000000:表示成功
|
||||
*/
|
||||
@SerializedName("recode")
|
||||
private String recode;
|
||||
|
||||
/**
|
||||
* 结果信息
|
||||
*/
|
||||
@SerializedName("recode_info")
|
||||
private String recodeInfo;
|
||||
|
||||
/**
|
||||
* 系统流水号
|
||||
*/
|
||||
@SerializedName("sys_serial_no")
|
||||
private String sysSerialNo;
|
||||
|
||||
/**
|
||||
* 系统日期(YYYY-MM-DD)
|
||||
*/
|
||||
@SerializedName("sys_date")
|
||||
private String sysDate;
|
||||
|
||||
/**
|
||||
* 系统时间(YYYY-MM-DD hh:mm:ss)
|
||||
*/
|
||||
@SerializedName("sys_time")
|
||||
private String sysTime;
|
||||
@SerializedName("data")
|
||||
private List<InvoiceSettleMatchApiRespData> data;
|
||||
@Data
|
||||
@Accessors(chain = true)
|
||||
public static class InvoiceSettleMatchApiRespData implements Serializable{
|
||||
/**
|
||||
* 发票编号
|
||||
*/
|
||||
@SerializedName("invoice_no")
|
||||
private String invoiceNo;
|
||||
/**
|
||||
* 来账流水号
|
||||
*/
|
||||
@SerializedName("deposit_serial_no")
|
||||
private String depositSerialNo;
|
||||
/**
|
||||
* 结算金额
|
||||
*/
|
||||
@SerializedName("match_amount")
|
||||
private BigDecimal matchAmount;
|
||||
}
|
||||
}
|
||||
Loading…
Reference in New Issue