Files
MoviconHub/MoviconWebApi/Entities/DeviceState.cs
2025-09-15 17:59:48 +08:00

93 lines
2.8 KiB
C#
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
using FreeSql.DataAnnotations;
namespace MoviconWebApi.Entities
{
/// <summary>
/// 设备状态
/// </summary>
[Table(Name = "DeviceState")]
public class DeviceState
{
/// <summary>
/// 主键ID
/// </summary>
[Column(IsPrimary = true, IsIdentity = true)]
public long Id { get; set; }
/// <summary>
/// 设备码
/// </summary>
[Column(Name = "DeviceCode", StringLength = 100, IsNullable = true)]
public string? DeviceCode { get; set; }
/// <summary>
/// 设备名称
/// </summary>
[Column(Name = "DeviceName", StringLength = 100, IsNullable = true)]
public string? DeviceName { get; set; }
/// <summary>
/// 开机时长status为1
/// </summary>
[Column(Name = "PowerOnTime", IsNullable = true)]
public int? PowerOnTime { get; set; }
/// <summary>
/// 运行时长status为2
/// </summary>
[Column(Name = "RunTime", IsNullable = true)]
public int? RunTime { get; set; }
/// <summary>
/// 待机时长status为3
/// </summary>
[Column(Name = "StandbyTime", IsNullable = true)]
public int? StandbyTime { get; set; }
/// <summary>
/// 故障时长status为4
/// </summary>
[Column(Name = "FaultTime", IsNullable = true)]
public int? FaultTime { get; set; }
/// <summary>
/// 关机时长status为5
/// </summary>
[Column(Name = "ShutdownTime", IsNullable = true)]
public int? ShutdownTime { get; set; }
///// <summary>
///// 使用率(PowerOnTime+ RunTime+ StandbyTime+ FaultTime)/( EndTime- StartTime) 从ts_sh_device_status_change_log中计算
///// </summary>
//[Column(Name = "UseRatio", IsNullable = true)]
//public int? UseRatio { get; set; }
/// <summary>
/// 使用率(PowerOnTime+ RunTime+ StandbyTime+ FaultTime)/( EndTime- StartTime) 从ts_sh_device_status_change_log中计算
/// </summary>
[Column(Name = "UseRatio", StringLength = 100, IsNullable = true)]
public string? UseRatio { get; set; }
/// <summary>
/// 故障次数
/// </summary>
[Column(Name = "FaultNum", IsNullable = true)]
public int? FaultNum { get; set; }
/// <summary>
/// 作业次数,建议从作业数据表中取数据
/// </summary>
[Column(Name = "JobNum", IsNullable = true)]
public int? JobNum { get; set; }
/// <summary>
/// 创建时间
/// </summary>
[Column(ServerTime = DateTimeKind.Local, CanUpdate = false)]
public DateTime CreateTime { get; set; }
}
}