-
Notifications
You must be signed in to change notification settings - Fork 319
Design Document: Export to PDF and HTML with Jasper Reports
Currently there is just one hardcoded "template" of PDF report in GanttProject. Customization options basically come down to the choice of task/resource columns to be exported. We want to allow for building of arbitrary reports with layout and data chosen by the report designer. We want to use industry standard solution for report templates rather than our own home grown technology. Jasper Reports seems to be a reasonable choice for that.
There is UI in
CSV import uses Apache Commons CSV library and in particular its CSVParser
and CSVRecord
classes. There is a lot of non-trivial code in the export which we want to keep and don't want to duplicate. It seems that replacing CSVParser
and CSVRecord
classes with minimal required abstract interface and parameterizing CSV importer with implementation of that interface will make possible to reuse the code of importer for both CSV and Excel exports.
This approach was already successfully implemented in CSV Export code. Refer to the pull request for the details of refactoring in CSV export.
Relevant classes in GanttProject codebase:
-
GanttCSVOpen
-- the meat of CSV import, scans through the input records and makes their semantical analysis -
ImporterFromCsvFile
-- plugs into the import wizard UI
This feature should eventually be merged into master
and published in one of the future versions. The base integration branch for pull requests is prj2_master
. Please fork from this base branch and create pull request into this base branch.
We use Java 8 and Kotlin, feel free to choose the language and feel free to use modern features of Java 8 if needed.
We'll appreciate a few unit tests similar to already existing GPCsvImportTest
. Probably it would make sense to refactor test code so that it could be reused for both Excel and CSV input data.
The process is described on GanttProject doc pages. Please do follow the code style and code review process. Your code should be of high quality in both operational and reading aspects (that is, it should work and it should be readable to us), and please be prepared to pretty demanding code review.