package com.uas.finance.model;


import javax.persistence.*;
import java.io.Serializable;

/**
 * 供应商客户
 * created by shicr on 2017/12/20
 **/
@Entity
@Table(name = "updowncast")
public class Updowncast implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * ID
     */
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @Column(name = "udc_id")
    private Long id;

    /**
     * 名称
     */
    @Column(name = "udc_name")
    private String udc_name;

    /**
     * 企业uu
     *
     * @return
     */
    @Column(name = "udc_enuu")
    private Long enuu;

    /**
     * 产品
     */
    @Column(name = "udc_product")
    private String udc_product;

    /**
     * 上年交易额
     */
    @Column(name = "udc_lastyear")
    private Double udc_lastyear;

    /**
     * 今年交易额
     */
    @Column(name = "udc_thisyear")
    private Double udc_thisyear;

    /**
     * 结账方式及账期
     */
    @Column(name = "udc_payment")
    private String udc_payment;

    /**
     * 合作年限
     */
    @Column(name = "udc_cooperationyears")
    private Short udc_cooperationyears;

    /**
     * 客户资料id
     */
    @Column(name = "udc_cus_id")
    private Long cusId;

    /**
     *上/下游客户
     */
    @Column(name = "udc_kind")
    private String udc_kind;

    /**
     * ERP系统中的主键id
     */
    @Column(name = "erpId")
    private Long erpId;


    @ManyToOne(cascade = CascadeType.REFRESH)
    @JoinColumn(name = "udc_cus_id", insertable = false, updatable = false)
    private CustomerInfo customerInfo;

    public Long getErpId() {
        return erpId;
    }

    public void setErpId(Long erpId) {
        this.erpId = erpId;
    }

    public Long getCusId() {
        return cusId;
    }

    public void setCusId(Long cusId) {
        this.cusId = cusId;
    }

   /* public CustomerInfo getCustomerInfo() {
        return customerInfo;
    }

    public void setCustomerInfo(CustomerInfo customerInfo) {
        this.customerInfo = customerInfo;
    }*/

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public Long getEnuu() {
        return enuu;
    }

    public void setEnuu(Long enuu) {
        this.enuu = enuu;
    }

    public String getUdc_name() {
        return udc_name;
    }

    public void setUdc_name(String udc_name) {
        this.udc_name = udc_name;
    }

    public String getUdc_product() {
        return udc_product;
    }

    public void setUdc_product(String udc_product) {
        this.udc_product = udc_product;
    }

    public Double getUdc_lastyear() {
        return udc_lastyear;
    }

    public void setUdc_lastyear(Double udc_lastyear) {
        this.udc_lastyear = udc_lastyear;
    }

    public Double getUdc_thisyear() {
        return udc_thisyear;
    }

    public void setUdc_thisyear(Double udc_thisyear) {
        this.udc_thisyear = udc_thisyear;
    }

    public String getUdc_payment() {
        return udc_payment;
    }

    public void setUdc_payment(String udc_payment) {
        this.udc_payment = udc_payment;
    }

    public Short getUdc_cooperationyears() {
        return udc_cooperationyears;
    }

    public void setUdc_cooperationyears(Short udc_cooperationyears) {
        this.udc_cooperationyears = udc_cooperationyears;
    }

    public String getUdc_kind() {
        return udc_kind;
    }

    public void setUdc_kind(String udc_kind) {
        this.udc_kind = udc_kind;
    }
}
