package com.ankaibei.workFlow.webadmin.ankaibei.entity;


import javax.persistence.*;
import java.math.BigDecimal;
import java.util.Date;
import java.util.Objects;

/**
 * @author
 * @version 1.0
 * @description: 通讯费表
 * @date 2022/9/21 14:26
 */
@Entity
@Table(name = "communication_info", schema = "ankaibei", catalog = "")
public class CommunicationInfoEntity {
    private Integer communicationId;
    /**
     * 项目名称
     */
    private String projectName;
    /**
     * 申请费用
     */
    private BigDecimal applicationFee;
    /**
     * 备注
     */
    private String remark;
    /**
     * 创建用户
     */
    private String createUser;
    /**
     * 开始时间
     */
    private Date createDate;
    /**
     * 结束时间
     */
    private Date endDate;
    /**
     * 发票
     */
    private String invoice;

    /**
     * 工作流任务处理类型
     */
    private Integer flowTaskStatus;
    /**
     * 记录的创建时间
     */
    private Date createTime;


    @Basic
    @Column(name = "create_time")
    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    @Basic
    @Column(name = "flow_task_status")
    public Integer getFlowTaskStatus() {
        return flowTaskStatus;
    }

    public void setFlowTaskStatus(Integer flowTaskStatus) {
        this.flowTaskStatus = flowTaskStatus;
    }

    @Id
    @Column(name = "communication_id")
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    public Integer getCommunicationId() {
        return communicationId;
    }

    public void setCommunicationId(Integer communicationId) {
        this.communicationId = communicationId;
    }

    @Basic
    @Column(name = "project_name")
    public String getProjectName() {
        return projectName;
    }

    public void setProjectName(String projectName) {
        this.projectName = projectName;
    }

    @Basic
    @Column(name = "application_fee")
    public BigDecimal getApplicationFee() {
        return applicationFee;
    }

    public void setApplicationFee(BigDecimal applicationFee) {
        this.applicationFee = applicationFee;
    }

    @Basic
    @Column(name = "remark")
    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    @Basic
    @Column(name = "create_user")
    public String getCreateUser() {
        return createUser;
    }

    public void setCreateUser(String createUser) {
        this.createUser = createUser;
    }

    @Basic
    @Column(name = "create_date")
    public Date getCreateDate() {
        return createDate;
    }

    public void setCreateDate(Date createDate) {
        this.createDate = createDate;
    }

    @Basic
    @Column(name = "invoice")
    public String getInvoice() {
        return invoice;
    }

    public void setInvoice(String invoice) {
        this.invoice = invoice;
    }

    @Basic
    @Column(name = "end_date")
    public Date getEndDate() {
        return endDate;
    }

    public void setEndDate(Date endDate) {
        this.endDate = endDate;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        CommunicationInfoEntity that = (CommunicationInfoEntity) o;
        return communicationId == that.communicationId && Objects.equals(projectName, that.projectName) && Objects.equals(applicationFee, that.applicationFee) && Objects.equals(remark, that.remark) && Objects.equals(createUser, that.createUser) && Objects.equals(createDate, that.createDate);
    }

    @Override
    public int hashCode() {
        return Objects.hash(communicationId, projectName, applicationFee, remark, createUser, createDate);
    }

    @Override
    public String toString() {
        return "CommunicationInfoEntity{" +
                "communicationId=" + communicationId +
                ", projectName='" + projectName + '\'' +
                ", applicationFee=" + applicationFee +
                ", remark='" + remark + '\'' +
                ", createUser='" + createUser + '\'' +
                ", createDate=" + createDate +
                ", endDate=" + endDate +
                ", invoice='" + invoice + '\'' +
                '}';
    }
}
