using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace IStation.Application { /// /// /// public class MonitorWeekRecordDto { /// /// /// public MonitorWeekRecordDto() { } /// /// /// public MonitorWeekRecordDto(Model.MonitorWeekRecordPure rhs) { this.CorpID = rhs.CorpID; this.MonitorPointID = rhs.MonitorPointID; this.SignalID = rhs.SignalID; this.RecordType = rhs.RecordType; this.StartDay = rhs.StartDay; this.EndDay = rhs.EndDay; this.SrcTime = rhs.SrcTime; this.SrcValue = rhs.SrcValue; this.DataTime = rhs.DataTime; this.DataValue= rhs.DataValue; this.DataStatus = rhs.DataStatus; } /// /// /// public MonitorWeekRecordDto(Model.MonitorWeekRecordPure rhs, Model.Signal_SignalType signal) : this(rhs) { if (signal != null) { if (signal.TryConvert(rhs.DataValue, out double dataValue)) { this.DataValue = dataValue.ToString(); } } } /// /// 客户标识 /// public long CorpID { get; set; } /// /// 测点标识 /// public long MonitorPointID { get; set; } /// /// 信号标识 /// public long SignalID { get; set; } /// /// 记录类型 /// public Model.eMonitorType RecordType { get; set; } /// /// 开始日期 /// public DateTime StartDay { get; set; } /// /// 结束日期 /// public DateTime EndDay { get; set; } /// /// 原始时间 /// public DateTime? SrcTime { get; set; } /// /// 原始值 /// public string SrcValue { get; set; } /// /// 数据时间 /// public DateTime DataTime { get; set; } /// /// 数据值 /// public string DataValue { get; set; } /// /// 数据状态 /// public List DataStatus { get; set; } } }