package org.eco.als.domain.bo;

import org.eco.als.domain.LifetimeSpareParts;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import lombok.EqualsAndHashCode;
import jakarta.validation.constraints.*;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.eco.common.orm.core.domain.BaseEntity;

/**
 * 有寿件业务对象 als_lifetime_spare_parts_t
 *
 * @author wgk
 * @date 2024-12-14
 */
@Data
@EqualsAndHashCode(callSuper = true)
@AutoMapper(target = LifetimeSpareParts.class, reverseConvertGenerate = false)
public class LifetimeSparePartsBo extends BaseEntity{
    /**
     * 编号
     */
    private Long id;

    /**
     * 飞机编目
     */
    private String airId;

    /**
     * 飞机机号
     */
    private String airModelId;

    /**
     * 构型Id
     */
    private String configId;

    /**
     * 部件名称
     */
    @NotBlank(message = "部件名称不能为空")
    private String componentName;

    /**
     * 部件型号
     */
    @NotBlank(message = "部件型号不能为空")
    private String componentModel;

    /**
     * 部件编码
     */
    @NotBlank(message = "部件编码不能为空")
    private String componentNum;

    /**
     * 出厂日期
     */
    @NotNull(message = "出厂日期不能为空")
    @JsonFormat(pattern = "yyyy-MM-dd")
    private Date factoryDate;

    /**
     * 当前安装飞机
     */
    @NotBlank(message = "当前安装飞机不能为空")
    private String currentInstallAircraft;

    /**
     * 工作时次
     */
    @NotBlank(message = "工作时次不能为空")
    private String workTime;

    /**
     * 额定寿命
     */
    @NotBlank(message = "额定寿命不能为空")
    private String ratedLifetime;

    /**
     * 剩余寿命
     */
    private String remainingLifetime;


}
