using Microsoft.EntityFrameworkCore;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
namespace YBEE.EQM.Core;
///
/// 学期
///
[Comment("学期")]
[Table("base_semester")]
public class Semester : DEntityBase
{
///
/// 主键:2023~2024学年上期:20232,2023~2024学年下期:20241
///
[Comment("主键:2023~2024学年上期:20232,2023~2024学年下期:20241")]
[Key, DatabaseGenerated(DatabaseGeneratedOption.None)]
public override short Id { get; set; }
///
/// 学期类型
///
[Comment("学期类型")]
[Required, Column(TypeName = "smallint")]
public SemesterType SemesterType { get; set; }
///
/// 名称,2023至2024学年上学期
///
[Comment("名称,2023至2024学年上学期")]
[Required, StringLength(100)]
public string Name { get; set; }
///
/// 简称,2023~2024上
///
[Comment("简称,2023~2024上")]
[Required, StringLength(100)]
public string ShortName { get; set; }
///
/// 别名,2023年秋季
///
[Comment("别名,2023年秋季")]
[Required, StringLength(100)]
public string NickName { get; set; }
///
/// 别名简称,2023秋
///
[Comment("别名简称,2023秋")]
[Required, StringLength(100)]
public string NickShortName { get; set; }
///
/// 开始年份
///
[Comment("开始年份")]
[Required]
public short BeginYear { get; set; }
///
/// 结束年份
///
[Comment("结束年份")]
[Required]
public short EndYear { get; set; }
///
/// 是否当前学年
///
[Comment("是否当前学年")]
[Required]
public bool IsCurrent { get; set; } = false;
///
/// 备注
///
[Comment("备注")]
[StringLength(200)]
public string Remark { get; set; }
}