EquipmentAlarmRecord.cs
2.84 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
using FreeSql.DataAnnotations;
using HHECS.DataContract;
namespace HHECS.DAQShared.Models
{
/// <summary>
/// 设备报警记录
/// </summary>
[Table(Name = "daq_equipment_alarm_record", DisableSyncStructure = true)]
[Index($"uk_{nameof(EquipmentCode)}", $"{nameof(EquipmentCode)}", false)]
[Index($"uk_{nameof(EquipmentPropCode)}", $"{nameof(EquipmentPropCode)}", false)]
[Index($"uk_{nameof(EquipmentTypeCode)}", $"{nameof(EquipmentTypeCode)}", false)]
[Index($"uk_{nameof(FactoryCode)}", $"{nameof(FactoryCode)}", false)]
[Index($"uk_{nameof(ProjectCode)}", $"{nameof(ProjectCode)}", false)]
public class EquipmentAlarmRecord : BaseEntity<Guid>
{
/// <summary>
/// 设备编号/IOT云平台设备SN
/// </summary>
public string EquipmentCode { get; set; } = null!;
/// <summary>
/// 设备名称
/// </summary>
public string EquipmentName { get; set; } = null!;
/// <summary>
/// 设备属性编号
/// </summary>
public string EquipmentPropCode { get; set; }
/// <summary>
/// 设备属性名称
/// </summary>
public string EquipmentPropName { get; set; }
/// <summary>
/// 设备类型编号
/// </summary>
public string EquipmentTypeCode { get; set; } = null!;
/// <summary>
/// 节点/地址
/// </summary>
public string Tag { get; set; }
/// <summary>
/// 报警内容
/// </summary>
public string AlarmMessage { get; set; } = null!;
/// <summary>
/// 是否结束
/// </summary>
public bool IsEnd { get; set; }
/// <summary>
/// 项目编号
/// </summary>
public string ProjectCode { get; set; }
/// <summary>
/// 仓库编号
/// </summary>
public string FactoryCode { get; set; }
/// <summary>
/// 创建时间
/// </summary>
public DateTime CreateTime { get; set; }
/// <summary>
/// 修改时间
/// </summary>
public DateTime UpdateTime { get; set; }
/// <summary>
/// 用户处理时间
/// </summary>
public DateTime? UserHandleTime { get; set; }
/// <summary>
/// 数据处理端的数据处理时间
/// </summary>
public DateTime? HandleTime { get; set; }
/// <summary>
/// 是否已处理
/// </summary>
public bool IsHandled { get; set; }
/// <summary>
/// 备注(用于存储报警明细,多条数据用分号隔开)
/// </summary>
public string Remark { get; set; }
/// <summary>
/// 错误时长 (单位秒)
/// </summary>
public double ErrorDuration { get; set; }
}
}