LoadPortViewModel.cs 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143
  1. using System.Collections.Generic;
  2. using Aitex.Core.Util;
  3. using Aitex.Sorter.UI.Controls;
  4. using Aitex.Sorter.UI.ViewModel;
  5. using MECF.Framework.Common.CommonData;
  6. namespace EfemUI.Views.Maintenance
  7. {
  8. public class LoadPortData : NotifiableItem
  9. {
  10. public string DeviceName { get; set; }
  11. public bool IsNotPresent3 { get; set; }
  12. public bool IsNotPresent4 { get; set; }
  13. public bool IsNotPresent6 { get; set; }
  14. public bool IsNotProtrude { get; set; }
  15. public string CassetteState { get; set; }
  16. public string WaferSize { get; set; }
  17. }
  18. public class LoadPortViewModel : UIViewModelBase
  19. {
  20. public bool EnablePageControl
  21. {
  22. get { return !IsOnlineMode; }
  23. }
  24. [Subscription("System.IsOnlineMode")]
  25. public bool IsOnlineMode
  26. {
  27. get;
  28. set;
  29. }
  30. [Subscription("LP1.IsNotPresent3")]
  31. public bool LP1IsNotPresent3
  32. {
  33. get;
  34. set;
  35. }
  36. [Subscription("LP1.IsNotPresent4")]
  37. public bool LP1IsNotPresent4
  38. {
  39. get;
  40. set;
  41. }
  42. [Subscription("LP1.IsNotPresent6")]
  43. public bool LP1IsNotPresent6
  44. {
  45. get;
  46. set;
  47. }
  48. [Subscription("LP1.IsWaferNotProtrude")]
  49. public bool LP1NotProtrude
  50. {
  51. get;
  52. set;
  53. }
  54. [Subscription("LP1.WaferSize")]
  55. public string LP1WaferSize
  56. {
  57. get;
  58. set;
  59. }
  60. [Subscription("LP1.CassetteState")]
  61. public string LP1CassetteState
  62. {
  63. get;
  64. set;
  65. }
  66. [Subscription("LP2.IsNotPresent3")]
  67. public bool LP2IsNotPresent3
  68. {
  69. get;
  70. set;
  71. }
  72. [Subscription("LP2.IsNotPresent4")]
  73. public bool LP2IsNotPresent4
  74. {
  75. get;
  76. set;
  77. }
  78. [Subscription("LP2.IsNotPresent6")]
  79. public bool LP2IsNotPresent6
  80. {
  81. get;
  82. set;
  83. }
  84. [Subscription("LP2.IsWaferNotProtrude")]
  85. public bool LP2NotProtrude
  86. {
  87. get;
  88. set;
  89. }
  90. [Subscription("LP2.WaferSize")]
  91. public string LP2WaferSize
  92. {
  93. get;
  94. set;
  95. }
  96. [Subscription("LP2.CassetteState")]
  97. public string LP2CassetteState
  98. {
  99. get;
  100. set;
  101. }
  102. public LoadPortData LP1Data { get; set; }
  103. public LoadPortData LP2Data { get; set; }
  104. public LoadPortViewModel() : base("LoadPort" )
  105. {
  106. LP1Data = new LoadPortData() {DeviceName = "LP1"};
  107. LP2Data = new LoadPortData() { DeviceName = "LP2" };
  108. }
  109. protected override void InvokeAfterUpdateProperty(Dictionary<string, object> data)
  110. {
  111. base.InvokeAfterUpdateProperty(data);
  112. LP1Data.IsNotPresent3 = LP1IsNotPresent3;
  113. LP1Data.IsNotPresent4 = LP1IsNotPresent4;
  114. LP1Data.IsNotPresent6 = LP1IsNotPresent6;
  115. LP1Data.IsNotProtrude = LP1NotProtrude;
  116. LP1Data.CassetteState = LP1CassetteState;
  117. LP1Data.WaferSize = LP1WaferSize;
  118. LP2Data.IsNotPresent3 = LP2IsNotPresent3;
  119. LP2Data.IsNotPresent4 = LP2IsNotPresent4;
  120. LP2Data.IsNotPresent6 = LP2IsNotPresent6;
  121. LP2Data.IsNotProtrude = LP2NotProtrude;
  122. LP2Data.CassetteState = LP2CassetteState;
  123. LP2Data.WaferSize = LP2WaferSize;
  124. LP1Data.InvokePropertyChanged();
  125. LP2Data.InvokePropertyChanged();
  126. }
  127. }
  128. }