Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0033222Openbravo ERPA. Platformpublic2016-06-11 21:362016-06-20 12:46
guillermogil 
caristu 
immediatemajoralways
closedfixed 
5
 
3.0PR16Q3 
alostale
Core
Production - QA Approved
2015-10-27
3.0PR16Q1
https://code.openbravo.com/erp/devel/pi/rev/cbf2d65774b8afda5265c76b78642271a0a7246a [^]
No
0033222: ConcatPDFReport has a null pointer exception if is used without reportConfiguration parameter
ConcatPDFReport has a null pointer exception if is used without reportConfiguration parameter
Method concatPDFReport(List<JasperPrint> jasperPrintList, boolean createBookmarks,
      OutputStream outputStream)
is creating a null pointer exception
Create a call on concatPDFReport(List<JasperPrint> jasperPrintList, boolean createBookmarks,
      OutputStream outputStream)
Without any SimplePdfExporterConfiguration
On ReportingUtils.java:
   public static void concatPDFReport(List<JasperPrint> jasperPrintList, boolean createBookmarks,
      OutputStream outputStream, SimplePdfExporterConfiguration reportConfiguration)
      throws JRException {

    JRPdfExporter exporter = new JRPdfExporter();
    SimpleOutputStreamExporterOutput exporterOutput = new SimpleOutputStreamExporterOutput(
        outputStream);
    SimplePdfExporterConfiguration configuration = reportConfiguration != null ? reportConfiguration
        : new SimplePdfExporterConfiguration();

    reportConfiguration.setCreatingBatchModeBookmarks(createBookmarks);
    exporter.setConfiguration(configuration);
    exporter.setExporterInput(SimpleExporterInput.getInstance(jasperPrintList));
    exporter.setExporterOutput(exporterOutput);

    exporter.exportReport();
  }

Line:
    reportConfiguration.setCreatingBatchModeBookmarks(createBookmarks);
Should be:
    configuration.setCreatingBatchModeBookmarks(createBookmarks);
No tags attached.
depends on backport 00332253.0PR16Q2.1 closed caristu ConcatPDFReport has a null pointer exception if is used without reportConfiguration parameter 
depends on backport 00332263.0PR16Q1.4 closed caristu ConcatPDFReport has a null pointer exception if is used without reportConfiguration parameter 
caused by feature request 0030783 closed NaroaIriarte reduce the number of clicks to print documents 
Issue History
2016-06-11 21:36guillermogilNew Issue
2016-06-11 21:36guillermogilAssigned To => platform
2016-06-11 21:36guillermogilModules => Core
2016-06-11 21:36guillermogilTriggers an Emergency Pack => No
2016-06-13 08:51caristuRegression level => Production - QA Approved
2016-06-13 08:51caristuRegression date => 2015-10-27
2016-06-13 08:51caristuRegression introduced in release => 3.0PR16Q1
2016-06-13 08:51caristuRegression introduced by commit => https://code.openbravo.com/erp/devel/pi/rev/cbf2d65774b8afda5265c76b78642271a0a7246a [^]
2016-06-13 08:52caristuRelationship addedcaused by 0030783
2016-06-13 09:30alostalePrioritynormal => immediate
2016-06-13 09:46alostaleAssigned Toplatform => caristu
2016-06-13 09:46alostaleStatusnew => scheduled
2016-06-13 09:48alostaleStatusscheduled => acknowledged
2016-06-13 09:49alostaleStatusacknowledged => scheduled
2016-06-13 10:54hgbotCheckin
2016-06-13 10:54hgbotNote Added: 0087191
2016-06-13 10:54hgbotStatusscheduled => resolved
2016-06-13 10:54hgbotResolutionopen => fixed
2016-06-13 10:54hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/a53d8d5cb84048ba4be4cd75cb80ff6c4e88f691 [^]
2016-06-13 11:21caristuReview Assigned To => alostale
2016-06-17 19:38hudsonbotCheckin
2016-06-17 19:38hudsonbotNote Added: 0087606
2016-06-20 12:46alostaleNote Added: 0087663
2016-06-20 12:46alostaleStatusresolved => closed
2016-06-20 12:46alostaleFixed in Version => 3.0PR16Q3

Notes
(0087191)
hgbot   
2016-06-13 10:54   
Repository: erp/devel/pi
Changeset: a53d8d5cb84048ba4be4cd75cb80ff6c4e88f691
Author: Carlos Aristu <carlos.aristu <at> openbravo.com>
Date: Mon Jun 13 10:53:19 2016 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/a53d8d5cb84048ba4be4cd75cb80ff6c4e88f691 [^]

fixes issue 33222: ConcatPDFReport can throw a null pointer exception
Use the correct variable name (configuration instead of reportConfiguration) when using the setCreatingBatchModeBookmarks method

---
M modules/org.openbravo.client.application/src/org/openbravo/client/application/report/ReportingUtils.java
---
(0087606)
hudsonbot   
2016-06-17 19:38   
A changeset related to this issue has been promoted main and to the
Central Repository, after passing a series of tests.

Promotion changeset: https://code.openbravo.com/erp/devel/main/rev/0dc7be081b1c [^]
Maturity status: Test
(0087663)
alostale   
2016-06-20 12:46   
code reviewed + tested