using System; using System.Collections.Generic; using System.Text; namespace Core.Dtos { public class EQPDataDto { public string Topic { get; set; } public DateTime Date { get; set; } public List OutPuts { get; set; } = new List(); public List PSRates { get; set; } = new List(); public List ECRates { get; set; } = new List(); public List BTRates { get; set; } = new List(); public List FOGRates { get; set; } = new List(); public List FPLRates { get; set; } = new List(); public List RTVRates { get; set; } = new List(); public List AGRates { get; set; } = new List(); public List TPRates { get; set; } = new List(); public List FPCRates { get; set; } = new List(); public List FLRates { get; set; } = new List(); public List OTPRates { get; set; } = new List(); } public class OTPRateDto { public string Date { get; set; } public string Shift { get; set; } public PowerConsumptns PowerConsumptn { get; set; } } public class TPRateDto : TPRate { public string Date { get; set; } } public class FPCRateDto: FPCRate { public string Date { get; set; } } public class FLRateDto : FLRate { public string Date { get; set; } } public class AGRateDto : AGRate { public string Date { get; set; } } public class RTVRateDto : RTVRate { public string Date { get; set; } } public class OutPutPerHourDto : OutPutPerHour { public string Date { get; set; } public DateTime? DateTime { get { if (string.IsNullOrEmpty(Date) || string.IsNullOrEmpty(Period)) { return null; } string time = Period[..Period.IndexOf('~')]; return Convert.ToDateTime($"{Date} {time}:00"); } } public string ModuleTypeString { get { if (string.IsNullOrEmpty(ModuleType)) { return ""; } if (ModuleType.Length < 8) { return ModuleType; } return ModuleType[..8]; } } } #region PS public class PSRateInfoDto { public string Date { get; set; } public string Shift { get; set; } public List PSRatesOfEPD { get; set; } = new List(); public List PSRatesOfPS { get; set; } = new List(); public PowerConsumptns PowerConsumptn { get; set; } } #endregion #region EC public class ECRateDto { public string Date { get; set; } public string Shift { get; set; } public PowerConsumptns PowerConsumptn { get; set; } } #endregion #region BT public class BTRateInfoDto { public string Date { get; set; } public string Shift { get; set; } public List BTRatesOfAOI { get; set; } = new List(); public PowerConsumptns PowerConsumptn { get; set; } } #endregion #region FOG public class FOGRateDto : FOGRate { public string Date { get; set; } } #endregion public class FPLRateDto : FPLRate { public string Date { get; set; } } }