package org.dromara.inspection.domain.bo;

import org.dromara.common.core.validate.AddGroup;
import org.dromara.common.core.validate.EditGroup;
import org.dromara.common.mybatis.core.domain.BaseEntity;
import org.dromara.inspection.domain.ArStepRecord;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import lombok.EqualsAndHashCode;

import jakarta.validation.constraints.NotNull;
import java.util.Date;

/**
 * 步骤执行记录业务对象 ar_step_record
 *
 * @author Lion Li
 * @date 2025-01-13
 */

@Data
@EqualsAndHashCode(callSuper = true)
@AutoMapper(target = ArStepRecord.class, reverseConvertGenerate = false)
public class ArStepRecordBo extends BaseEntity {

    /**
     * 记录ID
     */
    @NotNull(message = "记录ID不能为空", groups = {EditGroup.class})
    private Long id;

    /**
     * 任务执行ID
     */
    @NotNull(message = "任务执行ID不能为空", groups = {AddGroup.class, EditGroup.class})
    private Long executionId;

    /**
     * 步骤ID
     */
    @NotNull(message = "步骤ID不能为空", groups = {AddGroup.class, EditGroup.class})
    private Long stepId;

    /**
     * 状态(pending待执行/completed已完成/skipped已跳过)
     */
    private String status;

    /**
     * 是否完成(0否 1是)
     */
    private String isDone;

    /**
     * 开始时间
     */
    private Date startTime;

    /**
     * 完成时间
     */
    private Date completionTime;

    /**
     * 耗时(秒)
     */
    private Integer duration;

    /**
     * 文本反馈
     */
    private String textFeedback;

    /**
     * 语音识别文本
     */
    private String voiceText;

    /**
     * AI识别结果(JSON)
     */
    private String aiResult;

    /**
     * 执行人ID
     */
    private Long executorId;

    /**
     * 执行人姓名
     */
    private String executorName;

}
