UP Permintaan Makanan dan Minuman Gizi
This commit is contained in:
parent
8ec5272edb
commit
90e7c9c721
@ -497,6 +497,7 @@ public class ReportingController {
|
||||
JasperExportManager.exportReportToPdfStream(jasperPrint, response.getOutputStream());
|
||||
}
|
||||
|
||||
|
||||
// Klinik Utama Bintaro
|
||||
|
||||
@RequestMapping(value = {"/bukti-layanan-farmasi-bintaro/{norec}/{user}"}, method = {RequestMethod.GET})
|
||||
|
||||
@ -326,6 +326,24 @@ public class ReportingDao {
|
||||
return null;
|
||||
}
|
||||
|
||||
public JasperPrint exportPdfPermintaanMinuman(int idRu, String tglAwal, String tglAkhir, String jenisDiet, String tglLayanan) {
|
||||
try (Connection conn = this.jdbcTemplate1.getDataSource().getConnection()) {
|
||||
String path = jasperDirPath + "pl_permintaan_minuman.jrxml";
|
||||
JasperReport jasperReport = JasperCompileManager.compileReport(path);
|
||||
Map<String, Object> parameters = new HashMap<>();
|
||||
parameters.put("idRu", idRu);
|
||||
parameters.put("tglAwal", tglAwal);
|
||||
parameters.put("tglAkhir", tglAkhir);
|
||||
parameters.put("jenisDiet", jenisDiet);
|
||||
parameters.put("tglLayanan", tglLayanan);
|
||||
return JasperFillManager.fillReport(jasperReport, parameters, conn);
|
||||
} catch (Exception var17) {
|
||||
LOG.error("Exception at exportPdfPermintaanMinuman");
|
||||
LOG.error(ReportingDao.class, var17);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public JasperPrint exportPdfRekapMakanan(int idRu, String tglAwal, String tglAkhir) {
|
||||
try (Connection conn = this.jdbcTemplate1.getDataSource().getConnection()) {
|
||||
String path = jasperDirPath + "pl_rekap_makan.jrxml";
|
||||
|
||||
@ -93,7 +93,11 @@ public class ReportingService {
|
||||
}
|
||||
|
||||
public JasperPrint printPdfPermintaanMakanan(int idRu, String tglAwal, String tglAkhir, String jenisDiet, String tglLayanan) {
|
||||
return this.reportingDao.exportPdfPermintaanMakanan(idRu, tglAwal, tglAkhir, jenisDiet, tglLayanan);
|
||||
if (Objects.equals(jenisDiet, "MINUMAN")) {
|
||||
return this.reportingDao.exportPdfPermintaanMinuman(idRu, tglAwal, tglAkhir, jenisDiet, tglLayanan);
|
||||
} else {
|
||||
return this.reportingDao.exportPdfPermintaanMakanan(idRu, tglAwal, tglAkhir, jenisDiet, tglLayanan);
|
||||
}
|
||||
}
|
||||
|
||||
public JasperPrint printPdfRekapMakanan(int idRu, String tglAwal, String tglAkhir) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user