Index: vhUnitTest/BL/PPS/common/impl/OnderdelenEtiketPrinterBase/EtikettenCommissieOne/TestPalletType.cls.xml =================================================================== diff -u -r54265 -r54278 --- vhUnitTest/BL/PPS/common/impl/OnderdelenEtiketPrinterBase/EtikettenCommissieOne/TestPalletType.cls.xml (.../TestPalletType.cls.xml) (revision 54265) +++ vhUnitTest/BL/PPS/common/impl/OnderdelenEtiketPrinterBase/EtikettenCommissieOne/TestPalletType.cls.xml (.../TestPalletType.cls.xml) (revision 54278) @@ -53,8 +53,8 @@ 1 - -DOM.AKP.ToeleveringService + +APPS.Halux.common.ProductieService 1 @@ -89,11 +89,9 @@ Set ..VerkoopAPIStub = ##class(vhTest.Mock.DOM.VKP.VerkoopAPI).MockInstance() Do ..VerkoopAPIStub.IndienMethodCall("GeefKlant",$$$ElkeWaarde).DanReturn(..DummyKlant) - Set ProductTypes = ##class(%ListOfDataTypes).%New() - Do ProductTypes.Insert(##class(DOM.PM.enu.ProductType).Legrabox()) - - Set ..ToeleveringService = ##class(vhTest.Mock.DOM.AKP.ToeleveringService).%New() - Do ..ToeleveringService.IndienMethodCall("GeefProductTypes", ..ToeleveringID).DanReturn(ProductTypes) + #dim Categorie As APPS.Halux.common.enu.Categorie = ##class(APPS.Halux.common.enu.Categorie).Legrabox() + Set ..ProductieService = ##class(vhTest.Mock.APPS.Halux.common.ProductieService).%New() + Do ..ProductieService.IndienMethodCall("GeefCategorieVoorToelevering", ..ToeleveringStub).DanReturn(Categorie) ]]> @@ -102,7 +100,7 @@ #dim VerzendingWijzeDHL1Dag As %String = "E01" Do ..OrderStub.IndienMethodCall("GeefVerzendingWijze").DanReturn(VerzendingWijzeDHL1Dag) - #dim OnderdelenEtiketPrinterBase As vhUnitTest.BL.PPS.common.impl.OnderdelenEtiketPrinterBase.SubClass = ##class(vhUnitTest.BL.PPS.common.impl.OnderdelenEtiketPrinterBase.SubClass).%New(..LogoBepalerMock, ..ToeleveringService) + #dim OnderdelenEtiketPrinterBase As vhUnitTest.BL.PPS.common.impl.OnderdelenEtiketPrinterBase.SubClass = ##class(vhUnitTest.BL.PPS.common.impl.OnderdelenEtiketPrinterBase.SubClass).%New(..LogoBepalerMock, ..ProductieService) #dim pxCommissie As BL.PPS.TBX.sub.pxCommissie = OnderdelenEtiketPrinterBase.EtikettenCommissieOne(..ToeleveringID, $$$DummyInteger, $$$DummyString) Do $$$AssertEquals(pxCommissie.PalletType, "WWPALLET") ]]> @@ -113,7 +111,7 @@ #dim StandaardVerzendwijze As %String = "" Do ..OrderStub.IndienMethodCall("GeefVerzendingWijze").DanReturn(StandaardVerzendwijze) - #dim OnderdelenEtiketPrinterBase As vhUnitTest.BL.PPS.common.impl.OnderdelenEtiketPrinterBase.SubClass = ##class(vhUnitTest.BL.PPS.common.impl.OnderdelenEtiketPrinterBase.SubClass).%New(..LogoBepalerMock, ..ToeleveringService) + #dim OnderdelenEtiketPrinterBase As vhUnitTest.BL.PPS.common.impl.OnderdelenEtiketPrinterBase.SubClass = ##class(vhUnitTest.BL.PPS.common.impl.OnderdelenEtiketPrinterBase.SubClass).%New(..LogoBepalerMock, ..ProductieService) #dim pxCommissie As BL.PPS.TBX.sub.pxCommissie = OnderdelenEtiketPrinterBase.EtikettenCommissieOne(..ToeleveringID, $$$DummyInteger, $$$DummyString) Do $$$AssertEquals(pxCommissie.PalletType, "") ]]> Index: BL/PPS/common/impl/OnderdelenEtiketPrinterBase.cls.xml =================================================================== diff -u -r54262 -r54278 --- BL/PPS/common/impl/OnderdelenEtiketPrinterBase.cls.xml (.../OnderdelenEtiketPrinterBase.cls.xml) (revision 54262) +++ BL/PPS/common/impl/OnderdelenEtiketPrinterBase.cls.xml (.../OnderdelenEtiketPrinterBase.cls.xml) (revision 54278) @@ -46,13 +46,13 @@ 1 - -DOM.AKP.ToeleveringService + +APPS.Halux.common.ProductieService 1 -LogoBepaler:BL.PPS.common.impl.OnderdelendoosLogoBepaler,ToeleveringService:DOM.AKP.ToeleveringService="" +LogoBepaler:BL.PPS.common.impl.OnderdelendoosLogoBepaler,ProductieService:APPS.Halux.common.ProductieService="" 1 1 %Status @@ -63,7 +63,7 @@ Set ..OrderAPI = ##class(DOM.DomeinContext).Instance().GeefOrderAPI() Set ..LegacyPartijAPI = ##class(DOM.DomeinContext).Instance().GeefLegacyPartijAPI() Set ..VerkoopAPI = ##class(DOM.DomeinContext).Instance().GeefVerkoopAPI() - Set ..ToeleveringService = $$$Inject(ToeleveringService, ##class(DOM.AKP.impl.ToeleveringService).%New()) + Set ..ProductieService = $$$Inject(ProductieService, ##class(APPS.Halux.common.ProductieService).%New()) Quit $$$OK ]]> @@ -105,7 +105,8 @@ Set pxLabel=##class(BL.PPS.TBX.sub.pxCommissie).%New() - If (##class(DOM.common.impl.ProjectSettingsAPI).%New().IsActiefAnderePrinterVoorTaxBatchesBijHalux() && ..IsToeleveringMetProductTypeTax(ToeleveringID)) { + If (##class(DOM.common.impl.ProjectSettingsAPI).%New().IsActiefAnderePrinterVoorTaxBatchesBijHalux() && + (..ProductieService.GeefCategorieVoorToelevering(Toelevering) = ##class(APPS.Halux.common.enu.Categorie).TAORbox())) { Set pxLabel.Device = ..#LabelPrinterTax } Else { Set pxLabel.Device = ..#LabelPrinter @@ -155,29 +156,6 @@ Quit CommissieRef ]]> - - -ToeleveringID:%String -1 -%Boolean - 1) { - Set Omschrijving = "Het ProductType van Toelevering '"_ToeleveringID_"' kon niet bepaald worden om de juiste etiketprinter te definiƫren. Er zitten meerdere ProductTypes in de Toelevering." - Set Exception = ##class(TECH.Exceptions.GeneralErrorException).%New(Omschrijving) - Do ##class(TECH.ExceptionHandler).Throw(Exception) - } - - Quit (ProductTypeLijst.GetAt(1) = ##class(DOM.PM.enu.ProductType).TAORbox()) -]]> - Index: vhUnitTest/BL/PPS/common/impl/OnderdelenEtiketPrinterBase/EtikettenCommissieOne/TestLogo.cls.xml =================================================================== diff -u -r54266 -r54278 --- vhUnitTest/BL/PPS/common/impl/OnderdelenEtiketPrinterBase/EtikettenCommissieOne/TestLogo.cls.xml (.../TestLogo.cls.xml) (revision 54266) +++ vhUnitTest/BL/PPS/common/impl/OnderdelenEtiketPrinterBase/EtikettenCommissieOne/TestLogo.cls.xml (.../TestLogo.cls.xml) (revision 54278) @@ -53,8 +53,8 @@ 1 - -DOM.AKP.ToeleveringService + +APPS.Halux.common.ProductieService 1 @@ -92,17 +92,15 @@ #dim StandaardVerzendwijze As %String = "" Do ..OrderStub.IndienMethodCall("GeefVerzendingWijze").DanReturn(StandaardVerzendwijze) - Set ProductTypes = ##class(%ListOfDataTypes).%New() - Do ProductTypes.Insert(##class(DOM.PM.enu.ProductType).Legrabox()) - - Set ..ToeleveringService = ##class(vhTest.Mock.DOM.AKP.ToeleveringService).%New() - Do ..ToeleveringService.IndienMethodCall("GeefProductTypes", ..ToeleveringID).DanReturn(ProductTypes) + #dim Categorie As APPS.Halux.common.enu.Categorie = ##class(APPS.Halux.common.enu.Categorie).Legrabox() + Set ..ProductieService = ##class(vhTest.Mock.APPS.Halux.common.ProductieService).%New() + Do ..ProductieService.IndienMethodCall("GeefCategorieVoorToelevering", ..ToeleveringStub).DanReturn(Categorie) ]]> 1 - -DOM.AKP.ToeleveringService + +APPS.Halux.common.ProductieService 1 @@ -92,29 +92,27 @@ #dim StandaardVerzendwijze As %String = "" Do ..OrderStub.IndienMethodCall("GeefVerzendingWijze").DanReturn(StandaardVerzendwijze) - Set ..ToeleveringService = ##class(vhTest.Mock.DOM.AKP.ToeleveringService).%New() + Set ..ProductieService = ##class(vhTest.Mock.APPS.Halux.common.ProductieService).%New() ]]>