Upgraded to JasperReports 5.0 (preserving compatibility with all previous releases) and POI 3.9 (preserving compatibility with POI 3.5+)
This commit is contained in:
parent
9caa514c69
commit
8fab14dfeb
|
|
@ -421,10 +421,10 @@ project("spring-context-support") {
|
|||
optional("org.apache.velocity:velocity:1.7")
|
||||
optional("org.freemarker:freemarker:2.3.15")
|
||||
optional("com.lowagie:itext:2.1.7")
|
||||
optional("jasperreports:jasperreports:2.0.5")
|
||||
optional("net.sf.jasperreports:jasperreports:5.0.4")
|
||||
optional("org.slf4j:slf4j-api:${slf4jVersion}")
|
||||
provided("javax.activation:activation:1.1")
|
||||
testCompile("org.apache.poi:poi:3.0.2-FINAL")
|
||||
testCompile("org.apache.poi:poi:3.9")
|
||||
testCompile("commons-beanutils:commons-beanutils:1.8.0") // for Velocity/JasperReports
|
||||
testCompile("commons-digester:commons-digester:1.8.1") // for Velocity/JasperReports
|
||||
testCompile("hsqldb:hsqldb:${hsqldbVersion}")
|
||||
|
|
@ -527,9 +527,9 @@ project("spring-webmvc") {
|
|||
optional("org.apache.tiles:tiles-jsp:2.1.2")
|
||||
optional("org.apache.tiles:tiles-servlet:2.1.2")
|
||||
optional("net.sourceforge.jexcelapi:jxl:2.6.3")
|
||||
optional("org.apache.poi:poi:3.0.2-FINAL")
|
||||
optional("org.apache.poi:poi:3.9")
|
||||
optional("com.lowagie:itext:2.1.7")
|
||||
optional("jasperreports:jasperreports:2.0.5") {
|
||||
optional("net.sf.jasperreports:jasperreports:5.0.4") {
|
||||
exclude group: "xml-apis", module: "xml-apis"
|
||||
}
|
||||
optional("rome:rome:1.0")
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright 2002-2012 the original author or authors.
|
||||
* Copyright 2002-2013 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
|
|
@ -122,7 +122,7 @@ public class JasperReportsUtilsTests extends TestCase {
|
|||
public void testRenderAsPdfWithExporterParameters() throws Exception {
|
||||
ByteArrayOutputStream os = new ByteArrayOutputStream();
|
||||
Map<JRExporterParameter, Object> exporterParameters = new HashMap<JRExporterParameter, Object>();
|
||||
exporterParameters.put(JRPdfExporterParameter.PDF_VERSION, JRPdfExporterParameter.PDF_VERSION_1_6.toString());
|
||||
exporterParameters.put(JRPdfExporterParameter.PDF_VERSION, JRPdfExporterParameter.PDF_VERSION_1_6);
|
||||
JasperReportsUtils.renderAsPdf(getReport(), getParameters(), getData(), os, exporterParameters);
|
||||
byte[] output = os.toByteArray();
|
||||
assertPdfOutputCorrect(output);
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright 2002-2009 the original author or authors.
|
||||
* Copyright 2002-2013 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
|
|
@ -35,7 +35,7 @@ import org.springframework.web.servlet.view.AbstractView;
|
|||
|
||||
/**
|
||||
* Convenient superclass for Excel document views.
|
||||
* Compatible with Apache POI 3.0 as well as 3.5, as of Spring 3.0.
|
||||
* Compatible with Apache POI 3.5 and higher, as of Spring 4.0.
|
||||
*
|
||||
* <p>Properties:
|
||||
* <ul>
|
||||
|
|
@ -203,9 +203,9 @@ public abstract class AbstractExcelView extends AbstractView {
|
|||
if (sheetRow == null) {
|
||||
sheetRow = sheet.createRow(row);
|
||||
}
|
||||
HSSFCell cell = sheetRow.getCell((short) col);
|
||||
HSSFCell cell = sheetRow.getCell(col);
|
||||
if (cell == null) {
|
||||
cell = sheetRow.createCell((short) col);
|
||||
cell = sheetRow.createCell(col);
|
||||
}
|
||||
return cell;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue