APPS.Halux.PPS.Activiteit.impl.UitvoeringInfoLijstVerwerkerBasis,TECH.Mockable DOM.AKP.ToeleveringAPI 1 APPS.Halux.PPS.Document.impl.common.BatchNaarObjective.BatchNaarObjectiveDataGenerator 1 APPS.Halux.PPS.MES.MESService 1 ToeleveringApi:DOM.AKP.ToeleveringAPI="",BatchNaarObjectiveDataGenerator:APPS.Halux.PPS.Document.impl.common.BatchNaarObjective.BatchNaarObjectiveDataGenerator="" 1 1 %Status 1 Lijst:APPS.Halux.PPS.dto.UitvoeringInfoLijst APPS.Halux.PPS.dto.UitvoeringResultaat UitvoeringInfoLijst:APPS.Halux.PPS.dto.UitvoeringInfoLijst %ListOfObjects ELEMENTTYPE="APPS.Halux.PPS.Document.impl.common.BatchNaarObjective.dto.BatchNaarObjectiveData" 0) { #dim BatchId As %String = UitvoeringInfoLijst.GetAt(1).BatchID #dim Batch As APPS.Halux.common.Batch = ##class(APPS.ApplicatieContext).Instance().GeefProductieAPI().GeefBatchService().GeefBatch(BatchId) #dim ToeleveringenIterator As TECH.Iterator = Batch.GeefToeleveringIterator() #dim UitvoeringInfoLijstIterator As TECH.Iterator = ##class(TECH.ListIterator).%New(UitvoeringInfoLijst) #dim IndexToelevering As %Integer = 0 If (..MESService.IsActiefVoorMes(Batch.GeefLijn(), 1)) { While ToeleveringenIterator.HasNext() { #dim ToeleveringId As %String = ToeleveringenIterator.Next().GeefID() #dim Toelevering As DOM.AKP.Toelevering = ..ToeleveringApi.GeefToelevering(ToeleveringId) Set IndexToelevering = IndexToelevering + 1 #dim BatchData As APPS.Halux.PPS.Document.impl.common.BatchNaarObjective.dto.BatchNaarObjectiveData = ..BatchNaarObjectiveDataGenerator.GenereerBatchDataVoorToelevering(Batch, Toelevering, IndexToelevering) Set BatchData.Opties = ##class(%ListOfObjects).%New() // LBX ! Set ToeleveringProductInfoOptiesGenerator = ##class(APPS.Halux.PPS.Document.impl.LBX.BatchNaarObjective.OptieGenerator.ToeleveringProductInfoOptiesGeneratorLbx).%New() Do ##class(TECH.ListUtils).AppendList(BatchData.Opties, ToeleveringProductInfoOptiesGenerator.GenereerOptiesVoorLade(Toelevering)) While (UitvoeringInfoLijstIterator.HasNext()) { #dim UitvoeringInfo As APPS.Halux.PPS.Activiteit.impl.common.dto.BatchNaarObjectiveUitvoeringInfo = UitvoeringInfoLijstIterator.Next() If (UitvoeringInfo.ToeleveringID = ToeleveringId) { #dim OptiesVoorAlleLades As %ListOfObjects = ..BatchNaarObjectiveDataGenerator.GenereerOptiesVoorLade(Toelevering, UitvoeringInfo) Do ##class(TECH.ListUtils).AppendList(BatchData.Opties, OptiesVoorAlleLades) } } Do UitvoeringInfoLijstIterator.Reset() Do BatchDataLijst.Insert(BatchData) } } } Quit BatchDataLijst ]]> BatchDataLijst:%ListOfObjects 1 BatchId:%String,Index:%Integer,Extensie:TECH.String 1 TECH.String