PurchaseMaterial.java
4.4 KB
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
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
package com.skua.modules.erp.entity;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.TableField;
import com.skua.core.aspect.annotation.Dict;
import com.skua.core.util.ConvertUtils;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.jeecgframework.poi.excel.annotation.Excel;
/**
* 采购物料清单
*/
@Data
@TableName("erp_purchase_material")
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@ApiModel(value="erp_purchase_material对象", description="采购物料清单")
public class PurchaseMaterial {
/**主键*/
@TableId(type = IdType.UUID)
@ApiModelProperty(value = "主键")
private String id;
@ApiModelProperty(value = "所属机构")
@Dict(dictTable = "sys_depart", dicCode="id", dicText = "depart_name")
private String departId;
/**采购计划编号*/
@Excel(name = "采购合同编号", width = 15)
@ApiModelProperty(value = "采购合同编号")
private String contractId;
/**物料类别编号*/
@Excel(name = "物料类别编号", width = 15)
@ApiModelProperty(value = "物料类别编号")
private String sparepartType;
/**物料编号*/
@Excel(name = "物料编号", width = 15)
@ApiModelProperty(value = "物料编号")
private String sparepartId;
@ApiModelProperty(value = "物料编码")
private String sparepartCode;
@ApiModelProperty(value = "物料名称")
private String sparepartName;
/**物料编号*/
@Excel(name = "货号", width = 15)
@ApiModelProperty(value = "货号")
private String goodCode;
/**规格型号*/
@Excel(name = "规格型号", width = 15)
@ApiModelProperty(value = "规格型号")
private String specification;
/**计量单位*/
@Excel(name = "计量单位", width = 15)
@ApiModelProperty(value = "计量单位")
private String measuringUnit;
@ApiModelProperty(value = "产地")
private String goodOrigin;
@ApiModelProperty(value = "品牌")
private String goodBrand;
/**计划采购数量*/
@Excel(name = "计划采购数量", width = 15)
@ApiModelProperty(value = "计划采购数量")
private String purchaseNum;
/**单价*/
@Excel(name = "单价", width = 15)
@ApiModelProperty(value = "单价")
private String unitPrice;
@Excel(name = "总价", width = 15)
@ApiModelProperty(value = "总价")
private String totalPrice;
/**备注*/
@Excel(name = "备注", width = 15)
@ApiModelProperty(value = "备注")
private String remark;
/**供应商编号*/
@Excel(name = "供应商编号", width = 15)
@ApiModelProperty(value = "供应商编号")
@Dict(dictTable = "ajh_supplier_manage", dicCode="id", dicText = "supp_name")
private String supplierId;
/**税额*/
@Excel(name = "税额", width = 15)
@ApiModelProperty(value = "税额")
private String taxAmount;
/**价税合计*/
@Excel(name = "价税合计", width = 15)
@ApiModelProperty(value = "价税合计")
private String totalPriceTax;
@TableField(exist=false)
@ApiModelProperty(value = "物料类别名称")
private String sparepartTypeName;
@TableField(exist=false)
@ApiModelProperty(value = "供应商名称")
private String supplierName;
@TableField(exist=false)
@ApiModelProperty(value = "厂站名称")
private String departName;
@TableField(exist=false)
@ApiModelProperty(value = "扩展:采购物料数量")
private String materialNum;
/**单价*/
@Excel(name = "分销单价", width = 15)
@ApiModelProperty(value = "扩展:分销单价")
private String distributPrice;
/**总价*/
@Excel(name = "分销总价", width = 15)
@ApiModelProperty(value = "扩展:分销总价")
private String distributTotalPrice;
@TableField(exist=false)
@ApiModelProperty(value = "扩展:货号物料入库数量")
private String storeNum;
@TableField(exist=false)
@ApiModelProperty(value = "扩展:剩余数量")
private Double remainNum;
@TableField(exist=false)
@ApiModelProperty(value = "采购合同编号")
private String purchaseContractId;
public String getPurchaseContractId() {
return this.getContractId();
}
public Double getRemainNum() {
remainNum = ConvertUtils.getDouble(this.getPurchaseNum() ,0d) - ConvertUtils.getDouble(this.getStoreNum() ,0d);// JSUtils.divide(this.getPurchaseNum() ,this.getStoreNum());
return remainNum;
}
}