Index: ProScan/UI/DnaCodeScherm.pas =================================================================== diff -u -r543 -r624 --- ProScan/UI/DnaCodeScherm.pas (.../DnaCodeScherm.pas) (revision 543) +++ ProScan/UI/DnaCodeScherm.pas (.../DnaCodeScherm.pas) (revision 624) @@ -25,6 +25,7 @@ imgPallet: TImage; imgLaatstGescand: TImage; imgExport: TImage; + lblAantalOpPallet: TLabel; procedure FormShow(Sender: TObject); procedure actPalletExecute(Sender: TObject); procedure actHomeExecute(Sender: TObject); @@ -51,6 +52,7 @@ procedure RondAfVhossBatch(); procedure ZetAfrondActieStatus(actief: boolean); function GeefJuisteToelevering(fDnaCodeAfmeldenResponse: DnaCodeAfmeldenResponse; fDnaCode: string): string; + function GeefAantalOpPallet(Palletcode: String): integer; public end; @@ -87,6 +89,7 @@ lblToeleveringData.Caption := UiContext.Toelevering; lblAantalGescand.Caption := ''; lblTotaalAantal.Caption := ''; + lblAantalOpPallet.Caption := IntToStr(GeefAantalOpPallet(UiContext.Pallet)); btnInfo.Visible := false; fImagesScherm.ilAlgemeen64.GetIcon(8, imgToelevering.Picture.Icon); fImagesScherm.ilAlgemeen64.GetIcon(9, imgPallet.Picture.Icon); @@ -630,7 +633,7 @@ lblLaatstGescandData.Caption := ''; imgLaatstGescand.Visible := false; end else begin - lblLaatstGescandData.Caption := TCommonFunctions.VerkorteDnaCode(UiContext.LaatsteDnaCode); + lblLaatstGescandData.Caption := Copy(UiContext.LaatsteDnaCode,5,3); imgLaatstGescand.Visible := true; end; end; @@ -804,4 +807,18 @@ end; end; +function TfmDnaCodeScherm.GeefAantalOpPallet(PalletCode: string): integer; +var + fAgent: TAgent; + fZoekViaPalletCodeResponse: ZoekViaPalletCodeResponse; + fAantal: integer; +begin + fAgent := TAgent.Create(UiContext); + fZoekViaPalletCodeResponse := fAgent.ZoekViaPalletCode(PalletCode); + fAgent.Free; + fAantal := length(fZoekViaPalletCodeResponse.DnaCodes); + fZoekViaPalletCodeResponse.Free; + Result := fAantal; +end; + end.