using SqlSugar;
using System.ComponentModel;
using XF.Domain.Repository;

namespace Hotline.Schedulings
{
	[Description("排班管理")]
	public class Scheduling : FullStateEntity
	{
		/// <summary>
		/// 排班人员ID
		/// </summary>
		[SugarColumn(ColumnDescription = "排班人员ID")]
		public string? SchedulingUserId { get; set; }

		/// <summary>
		/// 排班人员名称
		/// </summary>
		[SugarColumn(ColumnDescription = "排班人员名称")]
		public string? SchedulingUserName { get; set; }

		/// <summary>
		/// 
		/// </summary>
		[Navigate(NavigateType.OneToOne, nameof(SchedulingUserId))]
		public SchedulingUser SchedulingUser { get; set; }

		/// <summary>
		/// 
		/// </summary>
		[Navigate(NavigateType.OneToOne, nameof(ShiftId))]
		public SchedulingShift SchedulingShift { get; set; }

		/// <summary>
		/// 班次名称
		/// </summary>
		[SugarColumn(ColumnDescription = "班次名称")]
		public string? ShiftId { get; set; }

		/// <summary>
		/// 班次名称
		/// </summary>
		[SugarColumn(ColumnDescription = "班次名称")]
		public string? ShiftName { get; set; }

		/// <summary>
		/// 上班时间
		/// </summary>
		[SugarColumn(ColumnDataType = "time", ColumnDescription = "上班时间")]
		public TimeSpan? WorkingTime { get; set; }

		/// <summary>
		/// 下班时间
		/// </summary>
		[SugarColumn(ColumnDataType = "time", ColumnDescription = "下班时间")]
		public TimeSpan? OffDutyTime { get; set; }

		/// <summary>
		/// 排班时间
		/// </summary>
		[SugarColumn( ColumnDescription = "排班时间")]
		public DateTime? SchedulingTime { get; set; }

		/// <summary>
		/// 派单次数
		/// </summary>
		public int? SendOrderNum { get; set; }


		/// <summary>
		/// 登录派单次数
		/// </summary>
		public int? LoginSendOrderNum { get; set; }

		/// <summary>
		/// 提前派单次数
		/// </summary>
		public int? AdvancedSendOrderNum { get; set; }

		/// <summary>
		/// 是否上班
		/// </summary>
		public bool? AtWork { get; set; }
	}
}
