package easydo.technology.model;

import easydo.technology.annotation.NotTableField;
import easydo.technology.system.model.SysUser;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.math.BigDecimal;

/**
 * 派工人员子表
 * 表名: dispatch_user_item
 * 用于记录每个派工记录关联的操作工
 */
@EqualsAndHashCode(callSuper = true)
@Data
public class DispatchUserItem extends CommonModel {
    private String id;
    private String dispatchId;  // 关联 product_order_dispatch 表的 id
    private Long userId;        // 操作工ID
    
    // 以下字段为冗余字段，方便后续扩展每个用户的派工数据
    private String orderId;
    private String beginDate;
    private String endDate;
    private String status;
    private String routeId;
    private String bomId;
    private String stageId;
    private BigDecimal readyTimeHour;
    private BigDecimal processNum;
    private BigDecimal processTimeHour;
    private BigDecimal moveTimeHour;
    private BigDecimal moveNum;
    private Integer orderNum;
    private Boolean isReview;
    private Boolean isReport;
    private Boolean isRound;
    private String tenantId;
    private String createTime;
    private Long createId;

    @NotTableField
    private SysUser user;  // 关联的用户信息
}
