using System.Text;
namespace SHJX.Service.Model.CRUDModules
{
///
/// 设备任务
///
[Table("equipment_task")]
public class EquipmentTask
{
///
/// 主键自增列
///
[Key]
public int SerialKey { get; set; }
///
/// 波次号
///
public string WaveKey { get; set; }
///
/// 原始地址的名称
///
public string Source { get; set; }
///
/// 创建时间
///
public DateTime CreateTime { get; set; }
///
/// 状态
///
public TaskState Status { get; set; }
///
/// 源地址
///
public string From { get; set; }
///
/// 目标地址
///
public string To { get; set; }
///
/// 目标
///
public string Target { get; set; }
///
/// 滴定数量
///
public double Amount { get; set; }
///
/// 滴定结果
///
public double Result { get; set; }
///
/// 开启标定
///
public bool CalibrationEnable { get; set; }
///
/// 路由ID
///
public int RouteID { get; set; }
///
/// 执行步骤
///
public string RouteStep { get; set; }
///
/// 记录
///
public string Record { get; set; }
///
/// 路由类型
///
public string RouteType { get; set; }
///
/// 任务类型
///
public string TaskType { get; set; }
///
/// 酸碱性
///
public AcidBase AcidBaseProp { get; set; }
///
/// 任务详细名称
///
public string TaskDetailName { get; set; }
///
/// 取样体积(用户手动输入)
///
public double SampleVolume { get; set; }
///
/// 取样倍数
///
public double SampleMultiple { get; set; }
///
///快速滴定
///
public bool QuicklyTitration { get; set; }
///
/// 扩展1
///
public string Udf1 { get; set; }
///
/// 扩展2
///
public string Udf2 { get; set; }
///
/// 扩展3
///
public string Udf3 { get; set; }
public EquipmentTask()
{
CreateTime = DateTime.Now;
}
public override string ToString()
{
StringBuilder sb = new();
sb.Append($"SerialKey:{SerialKey},");
sb.Append($"WaveKey:{WaveKey},");
sb.Append($"Source:{Source},");
sb.Append($"CreateTime:{CreateTime},");
sb.Append($"Status:{(int)Status},");
sb.Append($"From:{From},");
sb.Append($"To:{To},");
sb.Append($"Target:{Target},");
sb.Append($"Amount:{Amount},");
sb.Append($"Result:{Result},");
sb.Append($"CalibrationEnable:{CalibrationEnable},");
sb.Append($"RouteID:{RouteID},");
sb.Append($"RouteStep:{RouteStep},");
sb.Append($"Record:{Record},");
sb.Append($"RouteType:{RouteType},");
sb.Append($"TaskType:{TaskType},");
sb.Append($"TaskDetailName:{TaskDetailName},");
sb.Append($"SampleQuality:{SampleVolume},");
sb.Append($"SampleMultiple:{SampleMultiple},");
sb.Append($"QuicklyTitration:{QuicklyTitration},");
sb.Append($"Udf1:{Udf1},");
sb.Append($"Udf2:{Udf2},");
sb.Append($"Udf3:{Udf3}");
return sb.ToString();
}
}
}