Index: FLOWTOE3.mac.rou =================================================================== diff -u -r58214 -r58219 --- FLOWTOE3.mac.rou (.../FLOWTOE3.mac.rou) (revision 58214) +++ FLOWTOE3.mac.rou (.../FLOWTOE3.mac.rou) (revision 58219) @@ -579,7 +579,7 @@ New R,LEVNr,TLNr,NTOENr,LCount, TLUNr,PRNr,OrderLijnVolgnummer New arSplit,SortKey,LastSortKey,Leverdag new Toelevering, KlantID,Product,ProductAPI - New AantallenInToeleveringTeller,ProductieService,ToeleveringSplitser + New AantallenInToeleveringTeller,ProductieService,ToeleveringSplitser, Aantal new ProductieService set ProductieService = ##class(APPS.Halux.common.ProductieService).%New() set ProductAPI = ##class(DOM.DomeinContext).Instance().GeefProductAPI() @@ -589,14 +589,16 @@ set KlantID = Toelevering.GeefKlantID() + Set LEVNr=$P(^KTO1(TOENr),D),TLNr=100 + For Set TLNr=$O(^KTO(LEVNr,TOENr,TLNr)) Quit:TLNr="" Do . Set R=^KTO(LEVNr,TOENr,TLNr),PRNr=$P(R,D,2),Aantal=$P(R,D,3) . Do AantallenInToeleveringTeller.VoegToe(Aantal, PRNr, KlantID) Set ToeleveringSplitser = ##class(APPS.Halux.common.impl.ToeleveringSplitser).%New(AantallenInToeleveringTeller) + Set TLNr=100 #dim Product As DOM.PM.Product - Set LEVNr=$P(^KTO1(TOENr),D),TLNr=100 // SortKey dient niet voor sortering, maar voor het aanduiden welke lijnen samen mogen blijven, en welke niet. For Set TLNr=$O(^KTO(LEVNr,TOENr,TLNr)) Quit:TLNr="" Do . Set R=^KTO(LEVNr,TOENr,TLNr),PRNr=$P(R,D,2),OrderLijnVolgnummer=$P(R,D,28)