113 lines
2.7 KiB
C#
Raw Permalink 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 SqlSugar;
using YD_Event.Core.Enum;
namespace YD_Event.Core.Entities;
/// <summary>
/// 项目表
/// </summary>
[SugarTable("Project")]
public class Project : Entity<long>, ISoftDelete, ICreatedUserId, ICreatedTime, IUpdatedUserId, IUpdatedTime, IAvailability
{
/// <summary>
/// 项目名称
/// </summary>
[SugarColumn(Length = 128)]
public string Name { get; set; }
/// <summary>
/// 项目类型(枚举)
/// </summary>
[SugarColumn(SqlParameterDbType = System.Data.DbType.Int32)]
public ProjectTypeEnum ProjectType { get; set; }
/// <summary>
/// 完成人数模式(0=单一值, 1=范围值)
/// </summary>
public int CompletionCountType { get; set; } = 0;
/// <summary>
/// 完成人数(单一值模式时有效)
/// </summary>
public int CompletionCount { get; set; }
/// <summary>
/// 完成人数最小值(范围值模式时有效)
/// </summary>
public int? CompletionCountMin { get; set; }
/// <summary>
/// 完成人数最大值(范围值模式时有效)
/// </summary>
public int? CompletionCountMax { get; set; }
/// <summary>
/// 费用(元)
/// </summary>
public decimal Fee { get; set; }
/// <summary>
/// 时长(分钟)
/// </summary>
public int DurationMinutes { get; set; }
/// <summary>
/// 时长(秒)
/// </summary>
public int DurationSeconds { get; set; }
/// <summary>
/// 备注
/// </summary>
[SugarColumn(ColumnDescription = "备注", Length = 500, IsNullable = true)]
public string? Remark { get; set; }
/// <summary>
/// 场地数量(编排用)
/// </summary>
public int VenueCount { get; set; }
/// <summary>
/// 排序索引(编排用)
/// </summary>
public int SortIndex { get; set; }
/// <summary>
/// 项目组别列表(导航属性)
/// </summary>
[SugarColumn(IsIgnore = true)]
public List<ProjectGroup>? Groups { get; set; }
/// <summary>
/// 可用状态
/// </summary>
public AvailabilityStatus Status { get; set; }
/// <summary>
/// 标记删除
/// </summary>
public bool DeleteMark { get; set; }
/// <summary>
/// 创建人
/// </summary>
public long CreatedUserId { get; set; }
/// <summary>
/// 创建时间
/// </summary>
public DateTime CreatedTime { get; set; }
/// <summary>
/// 更新人
/// </summary>
[SugarColumn(IsNullable = true)]
public long? UpdatedUserId { get; set; }
/// <summary>
/// 更新时间
/// </summary>
[SugarColumn(IsNullable = true)]
public DateTime? UpdatedTime { get; set; }
}