|
| 1 | +package com.github.binarywang.wxpay.bean.invoice; |
| 2 | + |
| 3 | +import com.google.gson.annotations.SerializedName; |
| 4 | +import lombok.Data; |
| 5 | + |
| 6 | +import java.io.Serializable; |
| 7 | +import java.util.List; |
| 8 | + |
| 9 | +/** |
| 10 | + * 服务商开具通用行业电子发票请求。 |
| 11 | + * |
| 12 | + * @see <a href="https://pay.weixin.qq.com/doc/v3/partner/4015792574">开具通用行业电子发票</a> |
| 13 | + */ |
| 14 | +@Data |
| 15 | +public class GeneralInvoiceRequest implements Serializable { |
| 16 | + private static final long serialVersionUID = 1L; |
| 17 | + |
| 18 | + @SerializedName("sub_mchid") |
| 19 | + private String subMchid; |
| 20 | + @SerializedName("fapiao_apply_id") |
| 21 | + private String fapiaoApplyId; |
| 22 | + @SerializedName("buyer_information") |
| 23 | + private BuyerInformation buyerInformation; |
| 24 | + @SerializedName("fapiao_information") |
| 25 | + private FapiaoInformation fapiaoInformation; |
| 26 | + |
| 27 | + @Data |
| 28 | + public static class FapiaoInformation implements Serializable { |
| 29 | + private static final long serialVersionUID = 1L; |
| 30 | + @SerializedName("fapiao_id") |
| 31 | + private String fapiaoId; |
| 32 | + @SerializedName("total_amount") |
| 33 | + private Integer totalAmount; |
| 34 | + private List<InvoiceItem> items; |
| 35 | + @SerializedName("export_business_policy_code") |
| 36 | + private Integer exportBusinessPolicyCode; |
| 37 | + @SerializedName("vat_refund_levy_code") |
| 38 | + private Integer vatRefundLevyCode; |
| 39 | + @SerializedName("billing_person_id") |
| 40 | + private String billingPersonId; |
| 41 | + @SerializedName("billing_person") |
| 42 | + private String billingPerson; |
| 43 | + @SerializedName("fapiao_bill_type") |
| 44 | + private String fapiaoBillType; |
| 45 | + @SerializedName("transaction_information") |
| 46 | + private List<TransactionInformation> transactionInformation; |
| 47 | + private String remark; |
| 48 | + } |
| 49 | + |
| 50 | + @Data |
| 51 | + public static class InvoiceItem implements Serializable { |
| 52 | + private static final long serialVersionUID = 1L; |
| 53 | + @SerializedName("tax_code") |
| 54 | + private String taxCode; |
| 55 | + @SerializedName("goods_name") |
| 56 | + private String goodsName; |
| 57 | + private String specification; |
| 58 | + private String unit; |
| 59 | + private Integer quantity; |
| 60 | + @SerializedName("total_amount") |
| 61 | + private Integer totalAmount; |
| 62 | + @SerializedName("tax_rate") |
| 63 | + private Integer taxRate; |
| 64 | + private Boolean discount; |
| 65 | + @SerializedName("preferential_policy_code") |
| 66 | + private Integer preferentialPolicyCode; |
| 67 | + } |
| 68 | + |
| 69 | + @Data |
| 70 | + public static class TransactionInformation implements Serializable { |
| 71 | + private static final long serialVersionUID = 1L; |
| 72 | + @SerializedName("pay_channel") |
| 73 | + private String payChannel; |
| 74 | + @SerializedName("transaction_id") |
| 75 | + private String transactionId; |
| 76 | + @SerializedName("out_trade_no") |
| 77 | + private String outTradeNo; |
| 78 | + private Integer amount; |
| 79 | + } |
| 80 | +} |
0 commit comments