package com.reading.platform.entity;

import com.baomidou.mybatisplus.annotation.*;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.time.LocalDateTime;

/**
 * 课时反馈实体
 */
@Data
@TableName("t_lesson_feedback")
@Schema(description = "课时反馈")
public class LessonFeedback {

    @Schema(description = "反馈 ID", accessMode = Schema.AccessMode.READ_ONLY)
    @TableId(type = IdType.ASSIGN_ID)
    private String id;

    @Schema(description = "课时 ID", requiredMode = Schema.RequiredMode.REQUIRED)
    private String lessonId;

    @Schema(description = "课程 ID", requiredMode = Schema.RequiredMode.REQUIRED)
    private String courseId;

    @Schema(description = "租户 ID", accessMode = Schema.AccessMode.READ_ONLY)
    private String tenantId;

    @Schema(description = "教师 ID", requiredMode = Schema.RequiredMode.REQUIRED)
    private String teacherId;

    @Schema(description = "整体评分 (1-5)", example = "4", minimum = "1", maximum = "5")
    private Integer overallRating;

    @Schema(description = "设计质量评分 (1-5)", example = "4", minimum = "1", maximum = "5")
    private Integer designQuality;

    @Schema(description = "参与度评分 (1-5)", example = "4", minimum = "1", maximum = "5")
    private Integer participation;

    @Schema(description = "目标达成度评分 (1-5)", example = "4", minimum = "1", maximum = "5")
    private Integer goalAchievement;

    @Schema(description = "环节反馈 JSON")
    private String stepFeedbacks;

    @Schema(description = "优点")
    private String pros;

    @Schema(description = "建议")
    private String suggestions;

    @Schema(description = "完成的活动 JSON")
    private String activitiesDone;

    @Schema(description = "创建人用户名", accessMode = Schema.AccessMode.READ_ONLY)
    @TableField(fill = FieldFill.INSERT)
    private String createdBy;

    @Schema(description = "创建时间", accessMode = Schema.AccessMode.READ_ONLY)
    @TableField(fill = FieldFill.INSERT)
    private LocalDateTime createdAt;

    @Schema(description = "更新时间", accessMode = Schema.AccessMode.READ_ONLY)
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private LocalDateTime updatedAt;

    @Schema(description = "更新人用户名", accessMode = Schema.AccessMode.READ_ONLY)
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private String updatedBy;

    @Schema(description = "是否删除 0-未删除 1-已删除", accessMode = Schema.AccessMode.READ_ONLY)
    @TableLogic
    private Integer deleted;

}
