2025-06-12 18:41:46 +08:00
|
|
|
using CommunityToolkit.Mvvm.ComponentModel;
|
2025-06-20 18:53:29 +08:00
|
|
|
using PMSWPF.Enums;
|
|
|
|
|
using SqlSugar;
|
|
|
|
|
using SqlSugar.DbConvert;
|
2025-06-12 18:41:46 +08:00
|
|
|
|
2025-06-10 22:13:06 +08:00
|
|
|
namespace PMSWPF.Models;
|
|
|
|
|
|
2025-06-23 17:01:06 +08:00
|
|
|
public partial class Device : ObservableObject
|
2025-06-10 22:13:06 +08:00
|
|
|
{
|
2025-06-23 17:01:06 +08:00
|
|
|
[ObservableProperty] private string description;
|
|
|
|
|
|
|
|
|
|
[ObservableProperty] private int id;
|
|
|
|
|
|
|
|
|
|
[ObservableProperty] private string ip;
|
|
|
|
|
|
|
|
|
|
[ObservableProperty] private bool isActive = true;
|
|
|
|
|
|
|
|
|
|
[ObservableProperty] private bool isRuning;
|
|
|
|
|
|
|
|
|
|
[ObservableProperty] private string name;
|
|
|
|
|
|
|
|
|
|
[SugarColumn(ColumnDataType = "varchar(20)", SqlParameterDbType = typeof(EnumToStringConvert))]
|
2025-06-20 18:53:29 +08:00
|
|
|
public DeviceType DeviceType { get; set; }
|
|
|
|
|
|
2025-06-23 17:01:06 +08:00
|
|
|
public List<VariableTable>? VariableTables { get; set; }
|
2025-06-20 18:53:29 +08:00
|
|
|
public ProtocolType ProtocolType { get; set; }
|
2025-06-10 22:13:06 +08:00
|
|
|
}
|