Ви не можете вибрати більше 25 тем
Теми мають розпочинатися з літери або цифри, можуть містити дефіси (-) і не повинні перевищувати 35 символів.
|
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- using BPA.Helper;
- using System.Collections.Concurrent;
- using System.Collections.ObjectModel;
- using System.Windows;
- using BPASmartClient.DosingSystemSingle.View;
-
-
- namespace BPASmartClient.DosingSystemSingle.ViewModel
- {
- public class DeviceListViewModel : ViewModelBase
- {
- public DeviceListViewModel()
- {
- DetailsCommand = new BPARelayCommand<object>((o) =>
- {
- if (o != null && o is string str)
- {
- ChangeDeviceNameView cdn = new ChangeDeviceNameView();
- ActionManage.GetInstance.Send("ChangeDeviceNameViewOpen", str);
- cdn.ShowDialog();
- }
- });
- devices = DeviceInquire.GetInstance.devices;
- }
-
- //public BPARelayCommand<object> ChangeNameCommand { get; set; }
-
- //public static ObservableCollection<Devices> devices { get; set; } = new ObservableCollection<Devices>();
- public ObservableCollection<Devices> devices { get; set; }
- }
-
- public class Devices : NotifyBase
- {
- public string IpAddress { get { return _mIpAddress; } set { _mIpAddress = value; OnPropertyChanged(); } }
- private string _mIpAddress;
-
- /// <summary>
- /// 设备编号
- /// </summary>
- public int DeviceNum { get { return _mDeviceNum; } set { _mDeviceNum = value; OnPropertyChanged(); } }
- private int _mDeviceNum;
-
- public string DeviceName { get { return _mDeviceName; } set { _mDeviceName = value; OnPropertyChanged(); } }
- private string _mDeviceName;
-
- }
- }
|