package com.njcn.rdms.module.project.dal.dataobject.workreport.monthly;

import com.baomidou.mybatisplus.annotation.FieldStrategy;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.njcn.rdms.framework.mybatis.core.dataobject.BaseDO;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.math.BigDecimal;
import java.time.LocalDate;
import java.time.LocalDateTime;

/**
 * 工作报告-月报主表。
 */
@TableName("rdms_work_report_monthly_report")
@Data
@EqualsAndHashCode(callSuper = true)
public class MonthlyReportDO extends BaseDO {

    @TableId
    private Long id;

    private Long reporterId;

    private String reporterName;

    @TableField(updateStrategy = FieldStrategy.ALWAYS)
    private String reporterDeptName;

    @TableField(updateStrategy = FieldStrategy.ALWAYS)
    private String reporterPostName;

    private Long supervisorUserId;

    private String supervisorName;

    private String periodKey;

    private String periodLabel;

    private LocalDate periodStartDate;

    private LocalDate periodEndDate;

    private String statusCode;

    private String signOffStatus;

    @TableField(updateStrategy = FieldStrategy.ALWAYS)
    private BigDecimal totalWorkHours;

    @TableField(updateStrategy = FieldStrategy.ALWAYS)
    private LocalDateTime submitTime;

    @TableField(updateStrategy = FieldStrategy.ALWAYS)
    private LocalDateTime approvalTime;

    @TableField(updateStrategy = FieldStrategy.ALWAYS)
    private String approvalComment;

    @TableField(updateStrategy = FieldStrategy.ALWAYS)
    private String lastStatusReason;
}
