@Override public void generatePrintForm(Reference reference, OutputStream outputStream) { ReportXml reportXml = new ReportXml(); if (reference.getPrintTemplate() == null || reference.getPrintTemplate().getFileName() == null) { setDefaultPrintTemplate(reference); } reportXml.setTemplateFileName(reference.getPrintTemplate().getFileName()); build(reportXml, studentDAO.findById(reference.getOwnerId()), reference.getPurpose()); ReportPdfProcessor.getInstance().generate(reportXml, outputStream); }
@Override public void generatePrintForm( StudentDossier dossier, Student student, OutputStream outputStream) { ReportXml reportXml = new ReportXml(); if (dossier.getPrintTemplate() == null || dossier.getPrintTemplate().getFileName() == null) { setDefaultPrintTemplate(dossier); } reportXml.setTemplateFileName(dossier.getPrintTemplate().getFileName()); build(reportXml, student); ReportPdfProcessor.getInstance().generate(reportXml, outputStream); }
@Override public void generatePrintForm(List<Reference> references, OutputStream outputStream) { List<Report> reports = new ArrayList<Report>(); for (Reference reference : references) { ReportXml reportXml = new ReportXml(); if (reference.getPrintTemplate() == null || reference.getPrintTemplate().getFileName() == null) { setDefaultPrintTemplate(reference); } reportXml.setTemplateFileName(reference.getPrintTemplate().getFileName()); build(reportXml, studentDAO.findById(reference.getOwnerId()), reference.getPurpose()); reports.add(reportXml); } ReportPdfProcessor.getInstance().generate(reports, outputStream); }
@Override public void generatePrintForm( List<StudentDossier> dossiers, Student student, OutputStream outputStream) { List<Report> reports = new ArrayList<Report>(); for (StudentDossier dossier : dossiers) { ReportXml reportXml = new ReportXml(); if (dossier.getPrintTemplate() == null || dossier.getPrintTemplate().getFileName() == null) { setDefaultPrintTemplate(dossier); } reportXml.setTemplateFileName(dossier.getPrintTemplate().getFileName()); build(reportXml, student); reports.add(reportXml); } ReportPdfProcessor.getInstance().generate(reports, outputStream); }