HistoryDataItem.cs 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Runtime.Serialization;
  5. using System.Text;
  6. using SciChart.Core.Extensions;
  7. namespace Aitex.Sorter.Common
  8. {
  9. [DataContract]
  10. [Serializable]
  11. public class HistoryCarrierData
  12. {
  13. [DataMember]
  14. public string Guid { get; set; }
  15. [DataMember]
  16. public string Rfid { get; set; }
  17. [DataMember]
  18. public string Station { get; set; }
  19. [DataMember]
  20. public string LoadTime { get; set; }
  21. [DataMember]
  22. public string UnloadTime { get; set; }
  23. [DataMember]
  24. public string LotId { get; set; }
  25. [DataMember]
  26. public string ProductCategory { get; set; }
  27. [DataMember]
  28. public string ProcessPriority { get; set; }
  29. [DataMember]
  30. public string ProcessState { get; set; }
  31. }
  32. [DataContract]
  33. [Serializable]
  34. public class HistoryProcessData
  35. {
  36. [DataMember]
  37. public string Guid { get; set; }
  38. [DataMember]
  39. public string StartTime { get; set; }
  40. [DataMember]
  41. public string EndTime { get; set; }
  42. [DataMember]
  43. public string RecipeName { get; set; }
  44. [DataMember]
  45. public string Result { get; set; }
  46. //[DataMember]
  47. //public string Guid { get; set; }
  48. [DataMember]
  49. public string Rfid { get; set; }
  50. [DataMember]
  51. public string Station { get; set; }
  52. [DataMember]
  53. public string LotId { get; set; }
  54. [DataMember]
  55. public string ProductCategory { get; set; }
  56. }
  57. [DataContract]
  58. [Serializable]
  59. public class HistoryStatisticsOCRData
  60. {
  61. [DataMember]
  62. public string Date { get; set; }
  63. [DataMember]
  64. public string Totaltimes { get; set; }
  65. [DataMember]
  66. public string Successfueltimes { get; set; }
  67. [DataMember]
  68. public string Failuretimes { get; set; }
  69. [DataMember]
  70. public string Result { get; set; }
  71. }
  72. [DataContract]
  73. [Serializable]
  74. public class StatsStatisticsData
  75. {
  76. [DataMember]
  77. public string Date { get; set; }
  78. [DataMember]
  79. public string Unknown { get; set; }
  80. [DataMember]
  81. public string Setup { get; set; }
  82. [DataMember]
  83. public string Idle { get; set; }
  84. [DataMember]
  85. public string Ready { get; set; }
  86. [DataMember]
  87. public string Executing { get; set; }
  88. [DataMember]
  89. public string Pause { get; set; }
  90. }
  91. [DataContract]
  92. [Serializable]
  93. public class HistoryOCRData
  94. {
  95. [DataMember]
  96. public string Guid { get; set; }
  97. [DataMember]
  98. public string wafer_id { get; set; }
  99. [DataMember]
  100. public string read_time { get; set; }
  101. [DataMember]
  102. public string source_lp { get; set; }
  103. [DataMember]
  104. public string source_carrier { get; set; }
  105. [DataMember]
  106. public string source_slot { get; set; }
  107. [DataMember]
  108. public string ocr_no { get; set; }
  109. [DataMember]
  110. public string ocr_job { get; set; }
  111. [DataMember]
  112. public string read_result { get; set; }
  113. [DataMember]
  114. public string lasermark { get; set; }
  115. [DataMember]
  116. public string ocr_score { get; set; }
  117. [DataMember]
  118. public string read_period { get; set; }
  119. }
  120. [DataContract]
  121. [Serializable]
  122. public class HistoryWaferData
  123. {
  124. [DataMember]
  125. public string Guid { get; set; }
  126. [DataMember]
  127. public string CreateTime { get; set; }
  128. [DataMember]
  129. public string DeleteTime { get; set; }
  130. [DataMember]
  131. public string Station { get; set; }
  132. [DataMember]
  133. public string Slot { get; set; }
  134. [DataMember]
  135. public string LaserMarker { get; set; }
  136. [DataMember]
  137. public string LaserMarkerScore { get; set; }
  138. [DataMember]
  139. public string T7Code { get; set; }
  140. [DataMember]
  141. public string T7CodeScore { get; set; }
  142. [DataMember]
  143. public string LotId { get; set; }
  144. [DataMember]
  145. public string CarrierGuid { get; set; }
  146. [DataMember]
  147. public string WaferId { get; set; }
  148. [DataMember]
  149. public string ImageFileName { get; set; }
  150. [DataMember]
  151. public string ImageFilePath { get; set; }
  152. }
  153. [DataContract]
  154. [Serializable]
  155. public class HistoryMoveData
  156. {
  157. [DataMember]
  158. public string WaferGuid { get; set; }
  159. [DataMember]
  160. public string ArriveTime { get; set; }
  161. [DataMember]
  162. public string Station { get; set; }
  163. [DataMember]
  164. public string Slot { get; set; }
  165. [DataMember]
  166. public string Result { get; set; }
  167. }
  168. [DataContract]
  169. [Serializable]
  170. public class HistoryJobMoveData
  171. {
  172. [DataMember]
  173. public string JobGuid { get; set; }
  174. [DataMember]
  175. public string Station { get; set; }
  176. [DataMember]
  177. public string ProcessTime { get; set; }
  178. [DataMember]
  179. public string ArriveTime { get; set; }
  180. [DataMember]
  181. public string LeaveTime { get; set; }
  182. }
  183. [DataContract]
  184. [Serializable]
  185. public class HistoryBatData
  186. {
  187. [DataMember]
  188. public string Guid { get; set; }
  189. [DataMember]
  190. public string StartTime { get; set; }
  191. [DataMember]
  192. public string EndTime { get; set; }
  193. [DataMember]
  194. public string RecipeName { get; set; }
  195. [DataMember]
  196. public string Result { get; set; }
  197. }
  198. [DataContract]
  199. [Serializable]
  200. public class HistoryFfuDiffPressureData
  201. {
  202. [DataMember]
  203. public string Time { get; set; }
  204. [DataMember]
  205. public string FFU1Speed { get; set; }
  206. [DataMember]
  207. public string FFU2Speed { get; set; }
  208. [DataMember]
  209. public string DiffPressure1 { get; set; }
  210. [DataMember]
  211. public string DiffPressure2 { get; set; }
  212. }
  213. public interface ITreeItem<T> where T : ITreeItem<T>, new()
  214. {
  215. string ID { set; get; }
  216. }
  217. [DataContract]
  218. [Serializable]
  219. public enum WaferHistoryItemType
  220. {
  221. [EnumMember]
  222. None,
  223. [EnumMember]
  224. Lot,
  225. [EnumMember]
  226. Wafer,
  227. [EnumMember]
  228. Recipe
  229. }
  230. [DataContract]
  231. [Serializable]
  232. public class WaferHistoryMovement
  233. {
  234. [DataMember]
  235. public string Source { get; set; }
  236. [DataMember]
  237. public string Destination { get; set; }
  238. [DataMember]
  239. public string InTime { get; set; }
  240. }
  241. [DataContract]
  242. [Serializable]
  243. public class WaferHistoryWafer : WaferHistoryItem
  244. {
  245. [DataMember]
  246. public string ProcessJob { get; set; }
  247. [DataMember]
  248. public string Sequence { get; set; }
  249. [DataMember]
  250. public string Status { get; set; }
  251. public DateTime? ProcessStartTime { get; set; }
  252. [DataMember]
  253. public DateTime? ProcessEndTime { get; set; }
  254. [DataMember]
  255. public string SlotID { get; set; }
  256. public string ProcessDuration
  257. {
  258. get
  259. {
  260. if (!ProcessStartTime.HasValue || !ProcessEndTime.HasValue) return string.Empty;
  261. return ProcessEndTime.Value.Subtract(ProcessStartTime.Value).ToString(@"hh\:mm\:ss");
  262. }
  263. }
  264. }
  265. [DataContract]
  266. [Serializable]
  267. public class RecipeStep
  268. {
  269. [DataMember]
  270. public int No { get; set; }
  271. [DataMember]
  272. public string Name { get; set; }
  273. [DataMember]
  274. public DateTime StartTime { get; set; }
  275. [DataMember]
  276. public DateTime EndTime { get; set; }
  277. [DataMember]
  278. public string ActualTime { get; set; }
  279. [DataMember]
  280. public string SettingTime { get; set; }
  281. }
  282. [DataContract]
  283. [Serializable]
  284. public class RecipeStepFdcData
  285. {
  286. [DataMember]
  287. public int StepNumber { get; set; }
  288. [DataMember]
  289. public string Name { get; set; }
  290. [DataMember]
  291. public float SetPoint { get; set; }
  292. [DataMember]
  293. public int SampleCount { get; set; }
  294. [DataMember]
  295. public float MinValue { get; set; }
  296. [DataMember]
  297. public float MaxValue { get; set; }
  298. [DataMember]
  299. public float StdValue { get; set; }
  300. [DataMember]
  301. public float MeanValue { get; set; }
  302. }
  303. [DataContract]
  304. [Serializable]
  305. public class WaferHistoryRecipe : WaferHistoryItem
  306. {
  307. [DataMember]
  308. public string Chamber { get; set; }
  309. [DataMember]
  310. public string Recipe { get; set; }
  311. [DataMember]
  312. public string SettingTime { get; set; }
  313. [DataMember]
  314. public string ActualTime { get; set; }
  315. [DataMember]
  316. public List<RecipeStep> Steps { get; set; }
  317. [DataMember]
  318. public List<RecipeStepFdcData> Fdcs { get; set; }
  319. }
  320. public class WaferHistoryRecipe2 : WaferHistoryItem
  321. {
  322. [DataMember]
  323. public string Chamber { get; set; }
  324. [DataMember]
  325. public string Recipe { get; set; }
  326. [DataMember]
  327. public string SettingTime { get; set; }
  328. [DataMember]
  329. public string ActualTime { get; set; }
  330. [DataMember]
  331. public List<RecipeStep> Steps { get; set; }
  332. public object SelectedLot { get; set; }
  333. public object SelectedWafer { get; set; }
  334. public object SelectedProcess { get; set; }
  335. public bool IsToCompare { get; set; } = false;
  336. public object Cache { get; set; }// 临时的
  337. }
  338. [DataContract]
  339. [Serializable]
  340. public class WaferHistoryLot : WaferHistoryItem
  341. {
  342. [DataMember]
  343. public string CarrierID { get; set; }
  344. [DataMember]
  345. public string Rfid { get; set; }
  346. [DataMember]
  347. public string InputPort { get; set; }
  348. [DataMember]
  349. public int WaferCount { get; set; }
  350. [DataMember]
  351. public int FaultWaferCount { get; set; }
  352. }
  353. [DataContract]
  354. [Serializable]
  355. public class WaferHistorySecquence : WaferHistoryItem
  356. {
  357. [DataMember]
  358. public string SecquenceName { get; set; }
  359. [DataMember]
  360. public string Recipe { get; set; }
  361. [DataMember]
  362. public string SecQuenceStartTime { get; set; }
  363. [DataMember]
  364. public string SecQuenceEndTime { get; set; }
  365. [DataMember]
  366. public string ActualTime { get; set; }
  367. }
  368. [DataContract]
  369. [Serializable]
  370. public class WaferHistoryItem : ITreeItem<WaferHistoryItem>
  371. {
  372. [DataMember]
  373. public WaferHistoryItemType Type { get; set; }
  374. [DataMember]
  375. public string Name { get; set; }
  376. [DataMember]
  377. public string ID { get; set; }
  378. [DataMember]
  379. public DateTime StartTime { get; set; }
  380. [DataMember]
  381. public DateTime EndTime { get; set; }
  382. public string Duration => EndTime.CompareTo(StartTime) < 0 ? "" : EndTime.Subtract(StartTime).ToString(@"hh\:mm\:ss");
  383. public string ItemInfo => Name.IsNullOrEmpty() ? "" : Name;
  384. [DataMember]
  385. public ITreeItem<WaferHistoryItem> SubItems { get; set; }
  386. [DataMember]
  387. public string RfID { get; set; }
  388. [DataMember]
  389. public string LotID { get; set; }
  390. }
  391. [DataContract]
  392. [Serializable]
  393. public class WaferHistoryMetrology
  394. {
  395. [DataMember]
  396. public string dataname { get; set; }
  397. [DataMember]
  398. public string datavalue { get; set; }
  399. [DataMember]
  400. public string processtime { get; set; }
  401. [DataMember]
  402. public string stationname { get; set; }
  403. }
  404. }