refactor:将所有的ItemViewMdoel的名字删除ViewModel,并将命名空间调整为DMS.WPF.ItemViewModel.
This commit is contained in:
68
DMS.WPF/ItemViewModel/MqttServerItem.cs
Normal file
68
DMS.WPF/ItemViewModel/MqttServerItem.cs
Normal file
@@ -0,0 +1,68 @@
|
||||
using CommunityToolkit.Mvvm.ComponentModel;
|
||||
using DMS.Application.DTOs;
|
||||
using System;
|
||||
using System.Collections.ObjectModel;
|
||||
using System.Linq;
|
||||
|
||||
namespace DMS.WPF.ItemViewModel;
|
||||
|
||||
public partial class MqttServerItem : ObservableObject
|
||||
{
|
||||
public int Id { get; set; }
|
||||
|
||||
[ObservableProperty]
|
||||
private string _serverName;
|
||||
|
||||
[ObservableProperty]
|
||||
private string _serverUrl;
|
||||
|
||||
[ObservableProperty]
|
||||
private int _port;
|
||||
|
||||
[ObservableProperty]
|
||||
private string _username;
|
||||
|
||||
[ObservableProperty]
|
||||
private string _password;
|
||||
|
||||
[ObservableProperty]
|
||||
private bool _isActive;
|
||||
|
||||
[ObservableProperty]
|
||||
private bool _isConnect;
|
||||
|
||||
[ObservableProperty]
|
||||
private string _subscribeTopic;
|
||||
|
||||
[ObservableProperty]
|
||||
private string _publishTopic;
|
||||
|
||||
[ObservableProperty]
|
||||
private string _clientId;
|
||||
|
||||
[ObservableProperty]
|
||||
private DateTime _createdAt;
|
||||
|
||||
[ObservableProperty]
|
||||
private DateTime? _connectedAt;
|
||||
|
||||
[ObservableProperty]
|
||||
private long _connectionDuration;
|
||||
|
||||
[ObservableProperty]
|
||||
private string _messageFormat;
|
||||
|
||||
[ObservableProperty]
|
||||
private string _messageHeader;
|
||||
|
||||
[ObservableProperty]
|
||||
private string _messageContent;
|
||||
|
||||
[ObservableProperty]
|
||||
private string _messageFooter;
|
||||
|
||||
[ObservableProperty]
|
||||
private ObservableCollection<MqttAliasItem> _variableAliases = new();
|
||||
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user