package com.ruoyi.oa.domain;

import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.core.domain.entity.SysUser;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 安全汇报对象 cmc_safe_report
 *
 * @author cmc
 * @date 2024-06-24
 */
public class CmcSafeReport extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 安全报告id */
    private Integer safeReportId;

    /** 项目id */
    private String projectId;
    @Excel(name = "项目编号")
    private String projectNumber;
    @Excel(name = "项目名称")
    private String projectName;

    /** 公司人员 */
    private String member;
    @Excel(name = "公司人员")
    private String userName;

    /** 临时人员 */
    @Excel(name = "临时人员")
    private String employee;

    /** 安全报告 */
    @Excel(name = "安全报告")
    private String content;

    /** 填报人 */
    private Long reporter;
    @Excel(name = "填报人")
    private String reporterName;

    /** 报告日期 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "报告日期", width = 30, dateFormat = "yyyy-MM-dd")
    private Date reportDate;

    private SysUser reportUser;

    private CmcProject project;

    public void setSafeReportId(Integer safeReportId)
    {
        this.safeReportId = safeReportId;
    }

    public Integer getSafeReportId()
    {
        return safeReportId;
    }
    public void setProjectId(String projectId)
    {
        this.projectId = projectId;
    }

    public String getProjectId()
    {
        return projectId;
    }
    public void setProject(CmcProject project)
    {
        this.project = project;
        this.projectNumber = project == null ? "" : project.getProjectNumber();
        this.projectName = project == null ? "" : project.getProjectName();
    }

    public CmcProject getProject()
    {
        return project;
    }
    public void setReportDate(Date reportDate)
    {
        this.reportDate = reportDate;
    }

    public Date getReportDate()
    {
        return reportDate;
    }
    public void setMember(String member)
    {
        this.member = member;
    }

    public String getMember()
    {
        return member;
    }
    public void setUserName(String userName)
    {
        this.userName = userName;
    }

    public String getUserName()
    {
        return userName;
    }
    public void setReportUser(SysUser reportUser)
    {
        this.reportUser = reportUser;
        this.reporterName = reportUser == null ? "" : reportUser.getNickName();
    }

    public SysUser getReportUser()
    {
        return reportUser;
    }
    public void setEmployee(String employee)
    {
        this.employee = employee;
    }

    public String getEmployee()
    {
        return employee;
    }
    public void setContent(String content)
    {
        this.content = content;
    }

    public String getContent()
    {
        return content;
    }
    public void setReporter(Long reporter)
    {
        this.reporter = reporter;
    }

    public Long getReporter()
    {
        return reporter;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
                .append("safeReportId", getSafeReportId())
                .append("projectId", getProjectId())
                .append("reportDate", getReportDate())
                .append("member", getMember())
                .append("employee", getEmployee())
                .append("content", getContent())
                .append("reporter", getReporter())
                .toString();
    }
}
