| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859 | 
							- using System;
 
- using System.Collections.Generic;
 
- using System.Linq;
 
- using System.Text;
 
- using System.Threading.Tasks;
 
- using Aitex.Core.Common;
 
- using MECF.Framework.Common.DBCore;
 
- using MECF.Framework.Common.Equipment;
 
- using MECF.Framework.Common.Jobs;
 
- using MECF.Framework.Common.SubstrateTrackings;
 
- namespace Venus_RT.Modules.Schedulers
 
- {
 
-     class SchedulerDBCallback : ISchedulerDBCallback
 
-     {
 
-         public void LotCreated(ControlJobInfo cj)
 
-         {
 
-             ModuleName module = ModuleHelper.Converter(cj.Module);
 
-             Guid carrierGuid = CarrierManager.Instance.GetCarrier(cj.Module).InnerId;
 
-             LotDataRecorder.StartLot(cj.LotInnerId.ToString(), carrierGuid.ToString(), "", cj.LotName, cj.Module, cj.Module, cj.LotWafers.Count);
 
-             foreach (var waferInfo in cj.LotWafers)
 
-             {
 
-                 LotDataRecorder.InsertLotWafer(cj.LotInnerId.ToString(), waferInfo.InnerId.ToString());
 
-                 //WaferDataRecorder.SetWaferLotId(waferInfo.InnerId.ToString(), cj.LotName,waferInfo.SequenceName);
 
-             }
 
-         }
 
-         public void LotUpdate(ControlJobInfo cj)
 
-         {
 
-             foreach (var waferInfo in cj.LotWafers)
 
-             {
 
-                 WaferDataRecorder.SetWaferLotId(waferInfo.InnerId.ToString(), cj.LotName, waferInfo.SequenceName);
 
-             }
 
-         }
 
-         public void LotFinished(ControlJobInfo cj)
 
-         {
 
-             int unprocessed = 0;
 
-             int aborted = 0;
 
-             foreach (var waferInfo in cj.LotWafers)
 
-             {
 
-                 if (waferInfo.ProcessState == EnumWaferProcessStatus.Failed)
 
-                 {
 
-                     aborted++;
 
-                     continue;
 
-                 }
 
-                 if (waferInfo.ProcessState != EnumWaferProcessStatus.Completed)
 
-                 {
 
-                     unprocessed++;
 
-                     continue;
 
-                 }
 
-             }
 
-             LotDataRecorder.EndLot(cj.LotInnerId.ToString(), aborted, unprocessed);
 
-         }
 
-     }
 
- }
 
 
  |