GasLeakCheckViewModel.cs 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. using Prism.Commands;
  2. using Prism.Mvvm;
  3. using System;
  4. using System.Collections.Generic;
  5. using System.Linq;
  6. using System.Text;
  7. using System.Threading.Tasks;
  8. namespace Venus_MainPages.ViewModels
  9. {
  10. internal class GasLeakCheckViewModel : BindableBase
  11. {
  12. #region 私有字段
  13. private List<string> m_LeakCheckMode;
  14. private int m_LeakCheckModeSelectedIndex;
  15. private int m_VentTime;
  16. private int m_CheckTime;
  17. private bool[] m_GasIsCheck=new bool[8];
  18. #endregion
  19. #region 属性
  20. public List<string> LeakCheckMode
  21. {
  22. get { return m_LeakCheckMode; }
  23. set { SetProperty(ref m_LeakCheckMode, value); }
  24. }
  25. public int LeakCheckModeSelectedIndex
  26. {
  27. get { return m_LeakCheckModeSelectedIndex; }
  28. set { SetProperty(ref m_LeakCheckModeSelectedIndex, value); }
  29. }
  30. public int VentTime
  31. {
  32. get { return m_VentTime; }
  33. set { SetProperty(ref m_VentTime, value); }
  34. }
  35. public int CheckTime
  36. {
  37. get { return m_CheckTime; }
  38. set { SetProperty(ref m_CheckTime, value); }
  39. }
  40. public bool[] GasIsCheck
  41. {
  42. get { return m_GasIsCheck; }
  43. set { SetProperty(ref m_GasIsCheck, value); }
  44. }
  45. #endregion
  46. #region 命令
  47. private DelegateCommand _CheckCommand;
  48. public DelegateCommand CheckCommand =>
  49. _CheckCommand ?? (_CheckCommand = new DelegateCommand(OnCheck));
  50. #endregion
  51. #region 构造函数
  52. public GasLeakCheckViewModel()
  53. {
  54. m_LeakCheckMode = new List<string>() { "ChamberOnly", "ChamberAndGasLine", "ChamberAndGasLineAndFAC" };
  55. m_LeakCheckModeSelectedIndex = 0;
  56. m_VentTime = 120;
  57. m_CheckTime = 180;
  58. }
  59. #endregion
  60. #region 命令方法
  61. private void OnCheck()
  62. {
  63. }
  64. #endregion
  65. }
  66. }