using System; using System.Collections.Generic; using FreeSql.DataAnnotations; using ZhonTai.Admin.Core.Entities; using NPP.SmartSchedue.Api.Contracts.Core.Consts; namespace NPP.SmartSchedue.Api.Contracts.Domain.Time; /// /// 生产班次 /// [Table(Name = DbConsts.TableNamePrefix + "shift")] [Index("ix_shift_shiftnumber_enabled", nameof(ShiftNumber))] [Index("ix_shift_starttime_endtime", nameof(StartTime))] public partial class ShiftEntity : EntityTenant { /// /// 班次名称 /// [Column(StringLength = 100)] public string Name { get; set; } public int ShiftNumber { get; set; } /// /// 班次开始时间 /// public TimeSpan StartTime { get; set; } /// /// 班次结束时间 /// public TimeSpan EndTime { get; set; } public bool IsEnabled { get; set; } = true; /// /// 班次描述 /// [Column(StringLength = 200)] public string Description { get; set; } /// /// 班次后强制休息天数 (默认值,可被规则覆盖) /// public int RestDaysAfterShift { get; set; } = 1; /// /// 是否允许连续排班 (默认值,可被规则覆盖) /// public bool AllowConsecutive { get; set; } = false; /// /// 班次优先级权重 /// public int PriorityWeight { get; set; } = 1; }