zSTOCK do ClrScr("0101") set FP=0101 W @F,@FMTI,"RAADPLEGEN STOCK",@FMTi 10 New PRNr,Date set PRNr = $$SELECT^PRODUKT6() if PRNr="-" goto YZ 20 Set %INT="",%EXT="" For Set Date=$$ASK^vhINP("Datum: ",8,$G(Date)) Quit:"-"[Date Do VALDATE^vhDTyp(Date,"DK",$H) If %TC Set Date=%EXT Quit If Date="-" goto 10 do DisplayResult(PRNr,$G(%INT)) goto 10 YZ Quit ClrScr(Pos) set FP=Pos W @F,@F1 quit DisplayResult(PRNr,Datum) set Datum = $get(Datum) new StockService, StockServiceObj new Tijd , Tijd2, TijdObj, TijdObj2 new dtoStock set Product = ##class(DOM.DomeinContext).Instance().GeefProductAPI().GeefProduct(PRNr) do StartTimer^vhLib set StockService = ##class(APPS.common.impl.StockNiveauService).%New(PRNr,Datum) set dtoStock = StockService.GeefAlleStockTypeNiveaus() do StopTimer^vhLib set Tijd = $$GetInterval^vhLib() do ClrScr("0501") do Display("0602","Product : ",Product.GeefKorttekst()) do Display("0702","Omschr : ",Product.GeefOmschrijving()) if $length(Datum) Do Display("0702","Gewenste Datum : ",$$EXTDATE^vhDTyp(Datum)) do Display("0905","Fysische Stock : ",dtoStock.Fysisch) do Display("1005","Praktische Stock : ",dtoStock.Praktisch) do Display("1105","Theoretische Stock : ",dtoStock.Theoretisch) do Display("1205","In Order : ",dtoStock.InOrder) do Display("1305","In Toelev : ",dtoStock.InToelevering) do Display("1405","In Reservatie : ",dtoStock.InReservatie) do Display("1505","In Receptie : ",dtoStock.InReceptie) do Display("1605","Gestockeerd : ",dtoStock.InReceptieGestockeerd) do Display("1805","Tijd : ",Tijd) quit Display(Pos,String,Value) set FP=Pos write @F,@F2,String_Value quit