buhuazhen
12 小时以前 b62cf161a70805cfb0f33ade119a5ef5c47b3e7d
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
package com.ruoyi.sales.vo;
 
import com.ruoyi.basic.pojo.Customer;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
 
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.List;
import java.util.Optional;
 
import static com.ruoyi.common.utils.StringUtils.padRight;
 
/**
 * @author buhuazhen
 * @date 2026/3/18
 * @email 3038525872@qq.com
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
public class ExportProcessContractVo implements Serializable {
 
    private Long id;
 
    // yyyy年MM月dd日
    private String createTime;
 
 
    // 总金额(大写汉字)
    private String totalAmountZh;
 
    // 甲方
    private Customer partyA;
 
    // 乙方
    private Customer partyB;
 
    // 甲方公司名称
    private String partyAClientName;
 
    // 乙方公司名称
    private String partyBClientName;
 
    // 备注
    private String remark;
 
    private List<SaleProduct> saleProducts;
 
    // 签订地点
    private String placeOfSinging;
 
    private String taxRate;
 
 
    // 公式信息
    @Data
    @AllArgsConstructor
    @NoArgsConstructor
    public static class Customer implements Serializable {
        // 法人
        private String corporation = "";
 
        // 开户行
        private String bankName = "";
 
        //代理人
        private String agent = "";
 
        // 地址
        private String address = "";
 
        //传真
        private String fax = "";
 
        private String taxpayerIdentificationNumber = "";
 
        // 开户行号
        private String bankCode = "";
 
 
        // 邮编
        private String postCode = "";
 
        public static ExportProcessContractVo.Customer getCustomer(com.ruoyi.basic.pojo.Customer customer) {
            ExportProcessContractVo.Customer partyA = new ExportProcessContractVo.Customer();
            partyA.setFax(Optional.ofNullable(customer.getFax()).orElse(""));
            partyA.setAddress(padRight(customer.getCompanyAddress(), 15));
            partyA.setCorporation(Optional.ofNullable(customer.getCorporation()).orElse(""));
            partyA.setBankName(padRight(customer.getBankName(), 13));
            partyA.setAgent(Optional.ofNullable(customer.getAgent()).orElse(""));
            partyA.setTaxpayerIdentificationNumber(padRight(customer.getTaxpayerIdentificationNumber(), 15));
            partyA.setBankCode(padRight(customer.getBankCode(), 12));
            return partyA;
        }
    }
 
    @Data
    @AllArgsConstructor
    @NoArgsConstructor
    public static class SaleProduct implements Serializable {
        // 合同编号
        private String salesContractNo = "";
        private String productCategory = "";
        private String specificationModel = "";
        private BigDecimal quantity;
        // 税率
        private BigDecimal taxRate;
        // 含税单价
        private BigDecimal taxInclusiveUnitPrice;
        // 含税总价
        private BigDecimal taxInclusiveTotalPrice;
    }
}