终端一体化运控平台
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

43 line
1.5 KiB

  1. using System;
  2. using System.Collections.Generic;
  3. using System.Collections.ObjectModel;
  4. using System.Linq;
  5. using System.Text;
  6. using System.Threading.Tasks;
  7. using BPA.Helper;
  8. namespace BPASmartClient.DosingSystemSingle.ViewModel
  9. {
  10. public class StockControViewModel : NotifyBase
  11. {
  12. public StockControViewModel()
  13. {
  14. //Task.Factory.StartNew(() =>
  15. //{
  16. // App.Current.Dispatcher.Invoke(() =>
  17. // {
  18. // for (int i = 0; i < 6; i++)
  19. // {
  20. // statusTop.Add(new StockStatusModel { IsFault = false, IsLayOff = true, IsRunning = true, MaterialName = $"{i + 1}号料仓", MaterialWeight = 85 + i });
  21. // }
  22. // for (int i = 6; i < 12; i++)
  23. // {
  24. // statusDown.Add(new StockStatusModel { IsFault = false, IsLayOff = true, IsRunning = true, MaterialName = $"{i + 1}号料仓", MaterialWeight = 85 + i });
  25. // }
  26. // });
  27. //});
  28. statusTop = DeviceInquire.GetInstance.TopDeviceCurrentStatuses;
  29. statusDown = DeviceInquire.GetInstance.BottomDeviceCurrentStatuses;
  30. }
  31. public bool ConveyerBeltWork { get { return _mConveyerBeltWork; } set { _mConveyerBeltWork = value; OnPropertyChanged(); } }
  32. private bool _mConveyerBeltWork;
  33. public ObservableCollection<DeviceCurrentStatus> statusTop { get; set; }
  34. public ObservableCollection<DeviceCurrentStatus> statusDown { get; set; }
  35. }
  36. }