package com.storlead.sales.pojo.entity.material;

import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.storlead.framework.mybatis.entity.SysBaseField;
import com.baomidou.mybatisplus.annotation.TableId;

import java.time.LocalDate;
import java.time.LocalDateTime;
import java.util.List;

import com.baomidou.mybatisplus.annotation.TableField;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;

/**
 * <p>
 * 物料进场记录
 * </p>
 *
 * @author chenkq
 * @since 2025-05-16
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
@TableName("material_entry_record")
@ApiModel(value="MaterialEntryRecordEntity对象", description="物料进场记录")
public class MaterialEntryRecordEntity extends SysBaseField {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "主键id")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @ApiModelProperty(value = "检验类型")
    @TableField("inspection_type")
    private String inspectionType;

    @ApiModelProperty(value = "来料名称")
    @TableField("material_name")
    private String materialName;

    @ApiModelProperty(value = "品牌名称")
    @TableField("brand_name")
    private String brandName;

    @ApiModelProperty(value = "型号")
    @TableField("material_model")
    private String materialModel;

    @ApiModelProperty(value = "数量")
    @TableField("material_num")
    private String materialNum;

    @ApiModelProperty(value = "单位")
    @TableField("material_unit")
    private String materialUnit;

    @ApiModelProperty(value = "规格说明")
    @TableField("specs_des")
    private String specsDes;

    @ApiModelProperty(value = "用途")
    @TableField("use_des")
    private String useDes;

    @ApiModelProperty(value = "使用位置")
    @TableField("use_place_code")
    private String usePlaceCode;

    @ApiModelProperty(value = "施工类型")
    @TableField("construction_type")
    private String constructionType;

    @ApiModelProperty(value = "使用位置")
    @TableField("use_place_name")
    private String usePlaceName;

    @ApiModelProperty(value = "进入时间")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @TableField("entry_time")
    private LocalDate entryTime;

    @ApiModelProperty(value = "检验说明")
    @TableField("inspection_des")
    private String inspectionDes;

    @TableField(exist = false)
    @ApiModelProperty(value = "附件idList")
    private List<Long> resourceIdList;

    @TableField(exist = false)
    @ApiModelProperty(value = "是否可以删除或编辑,true 是，fales 否")
    private Boolean isEdit = false;

}
