|
|
@@ -1,1034 +0,0 @@
|
|
|
-package com.uas.platform.b2c.trade.order.model;
|
|
|
-
|
|
|
-import com.uas.platform.core.model.Status;
|
|
|
-import com.uas.platform.core.persistence.StatusColumn;
|
|
|
-
|
|
|
-import javax.persistence.CascadeType;
|
|
|
-import javax.persistence.Column;
|
|
|
-import javax.persistence.Entity;
|
|
|
-import javax.persistence.GeneratedValue;
|
|
|
-import javax.persistence.Id;
|
|
|
-import javax.persistence.JoinColumn;
|
|
|
-import javax.persistence.ManyToOne;
|
|
|
-import javax.persistence.Table;
|
|
|
-
|
|
|
-/**
|
|
|
- * 采购单明细 为了从明细关联主表
|
|
|
- *
|
|
|
- * @author yuj
|
|
|
- * @version 2017-08-02 18:28:01 创建文件
|
|
|
- */
|
|
|
-@Entity
|
|
|
-@Table(name = "trade$purchase_detail")
|
|
|
-public class PurchaseDetailMain extends Document {
|
|
|
-
|
|
|
- /**
|
|
|
- * ID
|
|
|
- */
|
|
|
- @Id
|
|
|
- @GeneratedValue
|
|
|
- @Column(name = "id")
|
|
|
- private Long id;
|
|
|
-
|
|
|
- /**
|
|
|
- * 主表
|
|
|
- *
|
|
|
- * @JsonIgnore
|
|
|
- */
|
|
|
- @ManyToOne(cascade = CascadeType.ALL, optional = true)
|
|
|
- @JoinColumn(name = "purchase_id", nullable = false)
|
|
|
- private Purchase purchase;
|
|
|
-
|
|
|
- /**
|
|
|
- * 明细序号 detailNO
|
|
|
- */
|
|
|
- @Column(name = "detno")
|
|
|
- private Short detno;
|
|
|
-
|
|
|
- /**
|
|
|
- * 采购单明细编号
|
|
|
- */
|
|
|
- @Column(name = "detail_id", unique = true)
|
|
|
- private String detailid;
|
|
|
-
|
|
|
- /**
|
|
|
- * 来源订单明细编号(也可以存id,编号可以带出来)
|
|
|
- *
|
|
|
- * @TODO 是否启用由 对于多个是用String+','还是用OneToMany决定
|
|
|
- */
|
|
|
- @Column(name = "orderdetail_id")
|
|
|
- private String orderdetailid;
|
|
|
-
|
|
|
- /**
|
|
|
- * 来源订单明细批次(这里多个订单转一个采购单,是先以卖家分组,再将同批次累加形成明细)
|
|
|
- *
|
|
|
- * @TODO 是否启用由 对于多个是用String+','还是用OneToMany决定
|
|
|
- */
|
|
|
- @Column(name = "go_batch")
|
|
|
- private String batchCode;
|
|
|
-
|
|
|
- /**
|
|
|
- * 对应的器件uuid
|
|
|
- */
|
|
|
- @Column(name = "cmp_uuid")
|
|
|
- private String uuid;
|
|
|
-
|
|
|
- /**
|
|
|
- * 开票的状态 700 待开发票 701 待收发票 702 已收发票 703 不需开票
|
|
|
- */
|
|
|
- @Column(name = "detail_billstatus")
|
|
|
- private Integer billStatus;
|
|
|
-
|
|
|
- /**
|
|
|
- * 发票的流水号
|
|
|
- */
|
|
|
- @Column(name = "detail_billnum")
|
|
|
- private String billNum;
|
|
|
-
|
|
|
- /**
|
|
|
- * 库存 1311 现货, 1312 呆滞库存, (暂时不用)废料 1313
|
|
|
- */
|
|
|
- @Column(name = "go_original")
|
|
|
- private Integer original;
|
|
|
-
|
|
|
- /**
|
|
|
- * 原厂型号
|
|
|
- */
|
|
|
- @Column(name = "cmp_code")
|
|
|
- private String cmpCode;
|
|
|
-
|
|
|
- /**
|
|
|
- * 器件所属类目
|
|
|
- */
|
|
|
- @Column(name = "ki_name")
|
|
|
- private String kiName;
|
|
|
-
|
|
|
- /**
|
|
|
- * 器件所属品牌
|
|
|
- */
|
|
|
- @Column(name = "br_name")
|
|
|
- private String brName;
|
|
|
-
|
|
|
- /**
|
|
|
- * 图片path
|
|
|
- */
|
|
|
- @Column(name = "cmp_img")
|
|
|
- private String img;
|
|
|
-
|
|
|
- /**
|
|
|
- * 未税单价,单位为元
|
|
|
- */
|
|
|
- @Column(name = "go_unitprice")
|
|
|
- private Double unitprice;
|
|
|
-
|
|
|
- /**
|
|
|
- * 含税单价,单位为元
|
|
|
- */
|
|
|
- @Column(name = "go_taxunitprice")
|
|
|
- private Double taxUnitPrice;
|
|
|
-
|
|
|
- /**
|
|
|
- * 数量
|
|
|
- */
|
|
|
- @Column(name = "detail_number")
|
|
|
- private Double number;
|
|
|
-
|
|
|
- /**
|
|
|
- * 已转数
|
|
|
- */
|
|
|
- @Column(name = "detail_num_done")
|
|
|
- private Double numberDone;
|
|
|
-
|
|
|
- /**
|
|
|
- * 待转数
|
|
|
- */
|
|
|
- @Column(name = "detail_num_todo")
|
|
|
- private Double numberTodo;
|
|
|
-
|
|
|
- /**
|
|
|
- * 税金
|
|
|
- */
|
|
|
- @Column(name = "detail_taxes")
|
|
|
- private Double taxes;
|
|
|
-
|
|
|
- /**
|
|
|
- * 价税总计
|
|
|
- */
|
|
|
- @Column(name = "detail_price")
|
|
|
- private Double price;
|
|
|
-
|
|
|
- /**
|
|
|
- * 确认金额(考虑商城打折的情况)
|
|
|
- */
|
|
|
- @Column(name = "ensure_price")
|
|
|
- private Double ensurePrice;
|
|
|
-
|
|
|
- /**
|
|
|
- * 实际成交金额(考虑退货)
|
|
|
- */
|
|
|
- @Column(name = "transation_price")
|
|
|
- private Double transationPrice;
|
|
|
-
|
|
|
- /**
|
|
|
- * 客户退货数量
|
|
|
- */
|
|
|
- @Column(name = "detail_returnqty")
|
|
|
- private Double returnQty;
|
|
|
-
|
|
|
- /**
|
|
|
- * 客户换货数量
|
|
|
- */
|
|
|
- @Column(name = "detail_changeqty")
|
|
|
- private Double changeQty;
|
|
|
-
|
|
|
- /**
|
|
|
- * 转的发货单明细单号
|
|
|
- */
|
|
|
- @Column(name = "inp_detailid")
|
|
|
- private String inpdetailid;
|
|
|
-
|
|
|
- /**
|
|
|
- * 采购单明细状态
|
|
|
- */
|
|
|
- @Column(name = "detail_status")
|
|
|
- @StatusColumn
|
|
|
- private Integer status;
|
|
|
-
|
|
|
- /**
|
|
|
- * 状态变更记录 List<StatusHistory> -> Json
|
|
|
- */
|
|
|
- @Column(name = "or_statushistory", length = 4000)
|
|
|
- private String statushistory;
|
|
|
-
|
|
|
- /**
|
|
|
- * 币别
|
|
|
- */
|
|
|
- @Column(name = "detail_currency")
|
|
|
- private String currencyName;
|
|
|
-
|
|
|
- /**
|
|
|
- * 税率
|
|
|
- */
|
|
|
- @Column(name = "detail_tax")
|
|
|
- private Short tax;
|
|
|
-
|
|
|
- /**
|
|
|
- * 是否支持7天无理由退货,1:支持,0:不支持
|
|
|
- */
|
|
|
- @Column(name = "detail_returninweek")
|
|
|
- private Short returnInWeek;
|
|
|
-
|
|
|
- /**
|
|
|
- * 计算确认总价
|
|
|
- *
|
|
|
- * @return double double
|
|
|
- */
|
|
|
- public Double ensurePrice() {
|
|
|
- Double enPrice = (double) 0;
|
|
|
- enPrice = (this.returnQty == null || (this.number - this.returnQty < 0)) ? this.price : ((this.number - this.returnQty) * this.unitprice);
|
|
|
- return enPrice;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets id.
|
|
|
- *
|
|
|
- * @return the id
|
|
|
- */
|
|
|
- public Long getId() {
|
|
|
- return id;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets id.
|
|
|
- *
|
|
|
- * @param id the id
|
|
|
- */
|
|
|
- public void setId(Long id) {
|
|
|
- this.id = id;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets detailid.
|
|
|
- *
|
|
|
- * @return the detailid
|
|
|
- */
|
|
|
- public String getDetailid() {
|
|
|
- return detailid;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets detailid.
|
|
|
- *
|
|
|
- * @param detailid the detailid
|
|
|
- */
|
|
|
- public void setDetailid(String detailid) {
|
|
|
- this.detailid = detailid;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets batch code.
|
|
|
- *
|
|
|
- * @return the batch code
|
|
|
- */
|
|
|
- public String getBatchCode() {
|
|
|
- return batchCode;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets uuid.
|
|
|
- *
|
|
|
- * @return the uuid
|
|
|
- */
|
|
|
- public String getUuid() {
|
|
|
- return uuid;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets uuid.
|
|
|
- *
|
|
|
- * @param uuid the uuid
|
|
|
- */
|
|
|
- public void setUuid(String uuid) {
|
|
|
- this.uuid = uuid;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets original.
|
|
|
- *
|
|
|
- * @return the original
|
|
|
- */
|
|
|
- public Integer getOriginal() {
|
|
|
- return original;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets original.
|
|
|
- *
|
|
|
- * @param original the original
|
|
|
- */
|
|
|
- public void setOriginal(Integer original) {
|
|
|
- this.original = original;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets cmp code.
|
|
|
- *
|
|
|
- * @return the cmp code
|
|
|
- */
|
|
|
- public String getCmpCode() {
|
|
|
- return cmpCode;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets cmp code.
|
|
|
- *
|
|
|
- * @param cmpCode the cmp code
|
|
|
- */
|
|
|
- public void setCmpCode(String cmpCode) {
|
|
|
- this.cmpCode = cmpCode;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets ki name.
|
|
|
- *
|
|
|
- * @return the ki name
|
|
|
- */
|
|
|
- public String getKiName() {
|
|
|
- return kiName;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets ki name.
|
|
|
- *
|
|
|
- * @param kiName the ki name
|
|
|
- */
|
|
|
- public void setKiName(String kiName) {
|
|
|
- this.kiName = kiName;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets br name.
|
|
|
- *
|
|
|
- * @return the br name
|
|
|
- */
|
|
|
- public String getBrName() {
|
|
|
- return brName;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets br name.
|
|
|
- *
|
|
|
- * @param brName the br name
|
|
|
- */
|
|
|
- public void setBrName(String brName) {
|
|
|
- this.brName = brName;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets img.
|
|
|
- *
|
|
|
- * @return the img
|
|
|
- */
|
|
|
- public String getImg() {
|
|
|
- return img;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets img.
|
|
|
- *
|
|
|
- * @param img the img
|
|
|
- */
|
|
|
- public void setImg(String img) {
|
|
|
- this.img = img;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets bill status.
|
|
|
- *
|
|
|
- * @return the bill status
|
|
|
- */
|
|
|
- public Integer getBillStatus() {
|
|
|
- return billStatus;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets bill status.
|
|
|
- *
|
|
|
- * @param billStatus the bill status
|
|
|
- */
|
|
|
- public void setBillStatus(Integer billStatus) {
|
|
|
- this.billStatus = billStatus;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets bill num.
|
|
|
- *
|
|
|
- * @return the bill num
|
|
|
- */
|
|
|
- public String getBillNum() {
|
|
|
- return billNum;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets bill num.
|
|
|
- *
|
|
|
- * @param billNum the bill num
|
|
|
- */
|
|
|
- public void setBillNum(String billNum) {
|
|
|
- this.billNum = billNum;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets batch code.
|
|
|
- *
|
|
|
- * @param batchCode the batch code
|
|
|
- */
|
|
|
- public void setBatchCode(String batchCode) {
|
|
|
- this.batchCode = batchCode;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets unitprice.
|
|
|
- *
|
|
|
- * @return the unitprice
|
|
|
- */
|
|
|
- public Double getUnitprice() {
|
|
|
- return unitprice;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets unitprice.
|
|
|
- *
|
|
|
- * @param unitprice the unitprice
|
|
|
- */
|
|
|
- public void setUnitprice(Double unitprice) {
|
|
|
- this.unitprice = unitprice;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets tax unit price.
|
|
|
- *
|
|
|
- * @return the tax unit price
|
|
|
- */
|
|
|
- public Double getTaxUnitPrice() {
|
|
|
- return taxUnitPrice;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets tax unit price.
|
|
|
- *
|
|
|
- * @param taxUnitPrice the tax unit price
|
|
|
- */
|
|
|
- public void setTaxUnitPrice(Double taxUnitPrice) {
|
|
|
- this.taxUnitPrice = taxUnitPrice;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets number.
|
|
|
- *
|
|
|
- * @return the number
|
|
|
- */
|
|
|
- public Double getNumber() {
|
|
|
- return number;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets number.
|
|
|
- *
|
|
|
- * @param number the number
|
|
|
- */
|
|
|
- public void setNumber(Double number) {
|
|
|
- this.number = number;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets taxes.
|
|
|
- *
|
|
|
- * @return the taxes
|
|
|
- */
|
|
|
- public Double getTaxes() {
|
|
|
- return taxes;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets taxes.
|
|
|
- *
|
|
|
- * @param taxes the taxes
|
|
|
- */
|
|
|
- public void setTaxes(Double taxes) {
|
|
|
- this.taxes = taxes;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets price.
|
|
|
- *
|
|
|
- * @return the price
|
|
|
- */
|
|
|
- public Double getPrice() {
|
|
|
- return price;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets price.
|
|
|
- *
|
|
|
- * @param price the price
|
|
|
- */
|
|
|
- public void setPrice(Double price) {
|
|
|
- this.price = price;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets status.
|
|
|
- *
|
|
|
- * @return the status
|
|
|
- */
|
|
|
- public Integer getStatus() {
|
|
|
- return status;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets status.
|
|
|
- *
|
|
|
- * @param status the status
|
|
|
- */
|
|
|
- public void setStatus(Integer status) {
|
|
|
- this.status = status;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets currency name.
|
|
|
- *
|
|
|
- * @return the currency name
|
|
|
- */
|
|
|
- public String getCurrencyName() {
|
|
|
- return currencyName;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets currency name.
|
|
|
- *
|
|
|
- * @param currencyName the currency name
|
|
|
- */
|
|
|
- public void setCurrencyName(String currencyName) {
|
|
|
- this.currencyName = currencyName;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets tax.
|
|
|
- *
|
|
|
- * @return the tax
|
|
|
- */
|
|
|
- public Short getTax() {
|
|
|
- return tax;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets tax.
|
|
|
- *
|
|
|
- * @param tax the tax
|
|
|
- */
|
|
|
- public void setTax(Short tax) {
|
|
|
- this.tax = tax;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets return in week.
|
|
|
- *
|
|
|
- * @return the return in week
|
|
|
- */
|
|
|
- public Short getReturnInWeek() {
|
|
|
- return returnInWeek;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets return in week.
|
|
|
- *
|
|
|
- * @param returnInWeek the return in week
|
|
|
- */
|
|
|
- public void setReturnInWeek(Short returnInWeek) {
|
|
|
- this.returnInWeek = returnInWeek;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets inpdetailid.
|
|
|
- *
|
|
|
- * @return the inpdetailid
|
|
|
- */
|
|
|
- public String getInpdetailid() {
|
|
|
- return inpdetailid;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets inpdetailid.
|
|
|
- *
|
|
|
- * @param inpdetailid the inpdetailid
|
|
|
- */
|
|
|
- public void setInpdetailid(String inpdetailid) {
|
|
|
- this.inpdetailid = inpdetailid;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets purchase.
|
|
|
- *
|
|
|
- * @return the purchase
|
|
|
- */
|
|
|
- public Purchase getPurchase() {
|
|
|
- return purchase;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets purchase.
|
|
|
- *
|
|
|
- * @param purchase the purchase
|
|
|
- */
|
|
|
- public void setPurchase(Purchase purchase) {
|
|
|
- this.purchase = purchase;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets detno.
|
|
|
- *
|
|
|
- * @return the detno
|
|
|
- */
|
|
|
- public Short getDetno() {
|
|
|
- return detno;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets detno.
|
|
|
- *
|
|
|
- * @param detno the detno
|
|
|
- */
|
|
|
- public void setDetno(Short detno) {
|
|
|
- this.detno = detno;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets orderdetailid.
|
|
|
- *
|
|
|
- * @return the orderdetailid
|
|
|
- */
|
|
|
- public String getOrderdetailid() {
|
|
|
- return orderdetailid;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets orderdetailid.
|
|
|
- *
|
|
|
- * @param orderdetailid the orderdetailid
|
|
|
- */
|
|
|
- public void setOrderdetailid(String orderdetailid) {
|
|
|
- this.orderdetailid = orderdetailid;
|
|
|
- }
|
|
|
-
|
|
|
- public PurchaseDetailMain() {
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets number done.
|
|
|
- *
|
|
|
- * @return the number done
|
|
|
- */
|
|
|
- public Double getNumberDone() {
|
|
|
- return numberDone;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets number done.
|
|
|
- *
|
|
|
- * @param numberDone the number done
|
|
|
- */
|
|
|
- public void setNumberDone(Double numberDone) {
|
|
|
- this.numberDone = numberDone;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets number todo.
|
|
|
- *
|
|
|
- * @return the number todo
|
|
|
- */
|
|
|
- public Double getNumberTodo() {
|
|
|
- return numberTodo;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets number todo.
|
|
|
- *
|
|
|
- * @param numberTodo the number todo
|
|
|
- */
|
|
|
- public void setNumberTodo(Double numberTodo) {
|
|
|
- this.numberTodo = numberTodo;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets ensure price.
|
|
|
- *
|
|
|
- * @return the ensure price
|
|
|
- */
|
|
|
- public Double getEnsurePrice() {
|
|
|
- return ensurePrice();
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets ensure price.
|
|
|
- *
|
|
|
- * @param ensurePrice the ensure price
|
|
|
- */
|
|
|
- public void setEnsurePrice(Double ensurePrice) {
|
|
|
- this.ensurePrice = ensurePrice;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets transation price.
|
|
|
- *
|
|
|
- * @return the transation price
|
|
|
- */
|
|
|
- public Double getTransationPrice() {
|
|
|
- return transationPrice;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets transation price.
|
|
|
- *
|
|
|
- * @param transationPrice the transation price
|
|
|
- */
|
|
|
- public void setTransationPrice(Double transationPrice) {
|
|
|
- this.transationPrice = transationPrice;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets return qty.
|
|
|
- *
|
|
|
- * @return the return qty
|
|
|
- */
|
|
|
- public Double getReturnQty() {
|
|
|
- return returnQty;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets return qty.
|
|
|
- *
|
|
|
- * @param returnQty the return qty
|
|
|
- */
|
|
|
- public void setReturnQty(Double returnQty) {
|
|
|
- this.returnQty = returnQty;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets change qty.
|
|
|
- *
|
|
|
- * @return the change qty
|
|
|
- */
|
|
|
- public Double getChangeQty() {
|
|
|
- return changeQty;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets change qty.
|
|
|
- *
|
|
|
- * @param changeQty the change qty
|
|
|
- */
|
|
|
- public void setChangeQty(Double changeQty) {
|
|
|
- this.changeQty = changeQty;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Instantiates a new Purchase detail main.
|
|
|
- *
|
|
|
- * @param oDetail the o detail
|
|
|
- */
|
|
|
- public PurchaseDetailMain(OrderDetail oDetail) {
|
|
|
- this.number = oDetail.getNumber();
|
|
|
- this.orderdetailid = oDetail.getDetailid();// 存放来源订单明细编号
|
|
|
- this.unitprice = oDetail.getUnitprice();
|
|
|
- this.taxUnitPrice = oDetail.getTaxUnitprice();
|
|
|
- this.taxes = oDetail.getTaxes();
|
|
|
- this.price = oDetail.getPrice();
|
|
|
- this.status = oDetail.getStatus();
|
|
|
- this.currencyName = oDetail.getCurrencyName();
|
|
|
- this.tax = oDetail.getTax();
|
|
|
- this.returnInWeek = oDetail.getReturnInWeek();
|
|
|
- // TODO 这里需要考虑确认总价的问题 (默认和总价相等,打折或优惠券逻辑待考虑)
|
|
|
- this.ensurePrice = oDetail.ensurePrice();
|
|
|
- this.batchCode = oDetail.getBatchCode();
|
|
|
- this.uuid = oDetail.getUuid();
|
|
|
- this.original = oDetail.getOriginal();
|
|
|
- this.cmpCode = oDetail.getCmpCode();
|
|
|
- this.brName = oDetail.getBrName();
|
|
|
- this.kiName = oDetail.getKiName();
|
|
|
- this.img = oDetail.getImg();
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets status to be confirmed.
|
|
|
- *
|
|
|
- * @param uu the uu
|
|
|
- */
|
|
|
- public void setStatusToBeConfirmed(Long uu) {
|
|
|
- this.status = Status.TOBECONFIRMED.value();
|
|
|
- this.statushistory = addStatusHistory(this.statushistory, uu, this.status);
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets status to be paid.
|
|
|
- *
|
|
|
- * @param uu the uu
|
|
|
- */
|
|
|
- public void setStatusToBePaid(Long uu) {
|
|
|
- this.status = Status.TOBEPAID.value();
|
|
|
- this.statushistory = addStatusHistory(this.statushistory, uu, this.status);
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets status to be shipped.
|
|
|
- *
|
|
|
- * @param uu the uu
|
|
|
- */
|
|
|
- public void setStatusToBeShipped(Long uu) {
|
|
|
- this.status = Status.TOBESHIPPED.value();
|
|
|
- this.statushistory = addStatusHistory(this.statushistory, uu, this.status);
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets status paid.
|
|
|
- *
|
|
|
- * @param uu the uu
|
|
|
- */
|
|
|
- public void setStatusPaid(Long uu) {
|
|
|
- this.status = Status.PAID.value();
|
|
|
- this.statushistory = addStatusHistory(this.statushistory, uu, this.status);
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets status shipped.
|
|
|
- *
|
|
|
- * @param uu the uu
|
|
|
- */
|
|
|
- public void setStatusShipped(Long uu) {
|
|
|
- this.status = Status.SHIPPED.value();
|
|
|
- this.statushistory = addStatusHistory(this.statushistory, uu, this.status);
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets status shipping in.
|
|
|
- *
|
|
|
- * @param uu the uu
|
|
|
- */
|
|
|
- public void setStatusShippingIn(Long uu) {
|
|
|
- this.status = Status.SHIPPINGIN.value();
|
|
|
- this.statushistory = addStatusHistory(this.statushistory, uu, this.status);
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets status sending.
|
|
|
- *
|
|
|
- * @param uu the uu
|
|
|
- */
|
|
|
- public void setStatusSending(Long uu) {
|
|
|
- this.status = Status.SENDING.value();
|
|
|
- this.statushistory = addStatusHistory(this.statushistory, uu, this.status);
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets status in bound.
|
|
|
- *
|
|
|
- * @param uu the uu
|
|
|
- */
|
|
|
- public void setStatusInBound(Long uu) {
|
|
|
- this.status = Status.INBOUND.value();
|
|
|
- this.statushistory = addStatusHistory(this.statushistory, uu, this.status);
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets status received.
|
|
|
- *
|
|
|
- * @param uu the uu
|
|
|
- */
|
|
|
- public void setStatusReceived(Long uu) {
|
|
|
- this.status = Status.RECEIVED.value();
|
|
|
- this.statushistory = addStatusHistory(this.statushistory, uu, this.status);
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets status un available.
|
|
|
- *
|
|
|
- * @param uu the uu
|
|
|
- */
|
|
|
- public void setStatusUnAvailable(Long uu) {
|
|
|
- this.status = Status.UNAVAILABLE.value();
|
|
|
- this.statushistory = addStatusHistory(this.statushistory, uu, this.status);
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets status un available personal.
|
|
|
- *
|
|
|
- * @param uu the uu
|
|
|
- */
|
|
|
- public void setStatusUnAvailablePersonal(Long uu) {
|
|
|
- this.status = Status.UNAVAILABLE_PERSONAL.value();
|
|
|
- this.statushistory = addStatusHistory(this.statushistory, uu, this.status);
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets status unavailable return.
|
|
|
- *
|
|
|
- * @param uu the uu
|
|
|
- */
|
|
|
- public void setStatusUnavailableReturn(Long uu) {
|
|
|
- this.status = Status.UNAVAILABLE_RETURN.value();
|
|
|
- this.statushistory = addStatusHistory(this.statushistory, uu, this.status);
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets status cancelled.
|
|
|
- *
|
|
|
- * @param uu the uu
|
|
|
- */
|
|
|
- public void setStatusCancelled(Long uu) {
|
|
|
- this.status = Status.CANCELLED.value();
|
|
|
- this.statushistory = addStatusHistory(this.statushistory, uu, this.status);
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets status unavailable disagree.
|
|
|
- *
|
|
|
- * @param uu the uu
|
|
|
- */
|
|
|
-/*
|
|
|
- * 供应商拒绝
|
|
|
- */
|
|
|
- public void setStatusUnavailableDisagree(Long uu) {
|
|
|
- this.status = Status.UNAVAILABLE_DISAGREE.value();
|
|
|
- this.statushistory = addStatusHistory(this.statushistory, uu, this.status);
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets status order take.
|
|
|
- *
|
|
|
- * @param uu the uu
|
|
|
- */
|
|
|
-/*
|
|
|
- * 卖家接单
|
|
|
- */
|
|
|
- public void setStatusOrderTake(Long uu) {
|
|
|
- this.status = Status.ORDERTAKE.value();
|
|
|
- this.statushistory = addStatusHistory(this.statushistory, uu, this.status);
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets status wait seller comfirm.
|
|
|
- *
|
|
|
- * @param uu the uu
|
|
|
- */
|
|
|
-/*
|
|
|
- * 等待卖家同意
|
|
|
- */
|
|
|
- public void setStatusWaitSellerComfirm(Long uu) {
|
|
|
- this.status = Status.WAITSELLERCOMFIRM.value();
|
|
|
- this.statushistory = addStatusHistory(this.statushistory, uu, this.status);
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * 售后中(只能单次单次的售后,暂时先这么处理)
|
|
|
- *
|
|
|
- * @param uu the uu
|
|
|
- * @return
|
|
|
- */
|
|
|
- public void setStatusInaftersales(Long uu) {
|
|
|
- this.status = Status.INAFTERSALES.value();
|
|
|
- this.statushistory = addStatusHistory(this.statushistory, uu, this.status);
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets status comfirm disagree.
|
|
|
- *
|
|
|
- * @param uu the uu
|
|
|
- */
|
|
|
-/*
|
|
|
- * 确认状态下的供应商拒绝
|
|
|
- */
|
|
|
- public void setStatusComfirmDisagree(Long uu) {
|
|
|
- this.status = Status.COMFIRM_DISAGREE.value();
|
|
|
- this.statushistory = addStatusHistory(this.statushistory, uu, this.status);
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets status paided disagree.
|
|
|
- *
|
|
|
- * @param uu the uu
|
|
|
- */
|
|
|
-/*
|
|
|
- * 付款状态下的供应商拒绝
|
|
|
- */
|
|
|
- public void setStatusPaidedDisagree(Long uu) {
|
|
|
- this.status = Status.PAIDED_DISAGREE.value();
|
|
|
- this.statushistory = addStatusHistory(this.statushistory, uu, this.status);
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Gets statushistory.
|
|
|
- *
|
|
|
- * @return the statushistory
|
|
|
- */
|
|
|
- public String getStatushistory() {
|
|
|
- return statushistory;
|
|
|
- }
|
|
|
-
|
|
|
- /**
|
|
|
- * Sets statushistory.
|
|
|
- *
|
|
|
- * @param statushistory the statushistory
|
|
|
- */
|
|
|
- public void setStatushistory(String statushistory) {
|
|
|
- this.statushistory = statushistory;
|
|
|
- }
|
|
|
-
|
|
|
- @Override
|
|
|
- public String toString() {
|
|
|
- return "PurchaseDetail [id=" + id + ", detno=" + detno + ", detailid=" + detailid + ", orderdetailid=" + orderdetailid + ", batchCode=" + batchCode + ", uuid=" + uuid + ", billStatus="
|
|
|
- + billStatus + ", billNum=" + billNum + ", original=" + original + ", cmpCode=" + cmpCode + ", kiName=" + kiName + ", brName=" + brName + ", img=" + img + ", unitprice=" + unitprice
|
|
|
- + ", taxUnitPrice=" + taxUnitPrice + ", number=" + number + ", numberDone=" + numberDone + ", numberTodo=" + numberTodo + ", taxes=" + taxes + ", price=" + price + ", ensurePrice="
|
|
|
- + ensurePrice + ", transationPrice=" + transationPrice + ", returnQty=" + returnQty + ", changeQty=" + changeQty + ", status=" + status + ", statushistory=" + statushistory
|
|
|
- + ", currencyName=" + currencyName + ", tax=" + tax + ", returnInWeek=" + returnInWeek + "]";
|
|
|
- }
|
|
|
-}
|