mi-assessment/server/MiAssessment/src/MiAssessment.Admin.Business/Entities/ScoreOption.cs
2026-02-22 23:18:37 +08:00

74 lines
1.6 KiB
C#
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

using System;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
namespace MiAssessment.Admin.Business.Entities;
/// <summary>
/// 评分标准选项表
/// </summary>
[Table("score_options")]
public class ScoreOption
{
/// <summary>
/// 主键ID
/// </summary>
[Key]
public long Id { get; set; }
/// <summary>
/// 测评类型ID
/// </summary>
public long AssessmentTypeId { get; set; }
/// <summary>
/// 分值1-10
/// </summary>
public int Score { get; set; }
/// <summary>
/// 等级标签(如:极弱、很弱)
/// </summary>
[Required]
[MaxLength(20)]
public string Label { get; set; } = null!;
/// <summary>
/// 描述(如:完全不符合)
/// </summary>
[Required]
[MaxLength(100)]
public string Description { get; set; } = null!;
/// <summary>
/// 排序
/// </summary>
public int Sort { get; set; }
/// <summary>
/// 状态0禁用 1启用
/// </summary>
public int Status { get; set; } = 1;
/// <summary>
/// 创建时间
/// </summary>
public DateTime CreateTime { get; set; }
/// <summary>
/// 更新时间
/// </summary>
public DateTime UpdateTime { get; set; }
/// <summary>
/// 软删除标记
/// </summary>
public bool IsDeleted { get; set; }
/// <summary>
/// 关联的测评类型
/// </summary>
[ForeignKey(nameof(AssessmentTypeId))]
public virtual AssessmentType? AssessmentType { get; set; }
}