Skip to content

Project for generate documents for word y excel of easy form.

License

Notifications You must be signed in to change notification settings

fochoac/report4j

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Quality Gate Status

REPORT4J

Utility component to generate excel, word and pdf documents.

Excel Report

  • Generate the template according to the specification of jxls.
  • Fill the variables according to the following methods:
 InputReportFile inputReportFile = new InputReportFile(PATH_TEMPLATE,
     MAP < String, Object > parameters);
 OutputReportFile outputReportFile = new OutputReportFile(TEMPORAL_FOLDER, "testPdf", OutputReportTypeEnum.PDF);
 ReportConfiguration configuration = new ReportConfiguration(inputReportFile, outputReportFile);
 Report excelReport = new ExcelReport(configuration);
 OutputReportFile report = excelReport.buildReport();
 report.saveFile();
 report.getFileBase64();

Word Report

  • Generate the chord template according to the example of the unit tests.
  • Fill the variables according to the following methods:
InputReportFile inputReportFile = new InputReportFile(PATH_TEMPLATE,
     MAP < String, Object > parameters);
 OutputReportFile outputReportFile = new OutputReportFile(TEMPORAL_FOLDER, "testPdf", OutputReportTypeEnum.PDF);
 ReportConfiguration configuration = new ReportConfiguration(inputReportFile, outputReportFile);
 Report report = new WordReport(configuration);
 OutputReportFile outReportFile = report.buildReport();
 outReportFile.saveFile();
 outReportFile.getFileBase64();

Export excel or word document to:

  • PDF
  • HTML
  • DOC or XLS only supports replace of variables into the document.

You want to collaborate with the project

Feel free to generate pull requests that help improve the functionality of the project. Any post change is welcome.