Update tagihan piutang

This commit is contained in:
ridwan 2025-05-05 08:51:01 +07:00
parent 0df5589a80
commit 0db404b8c5
3 changed files with 28 additions and 0 deletions

View File

@ -442,6 +442,15 @@ public class ReportingController {
JasperExportManager.exportReportToPdfStream(jasperPrint, response.getOutputStream());
}
@RequestMapping(value = {"/bukti-tagihan-piutang/{noposting}"}, method = {RequestMethod.GET})
public void exportPdfTagihanPiutang(@PathVariable("noposting") String norec,
@RequestParam(value = "PrintBy", required = false, defaultValue = "") String PrintBy,
ModelAndView mv, HttpServletResponse response) throws Exception {
JasperPrint jasperPrint = this.reportingService.exportPdfTagihanPiutang(norec, PrintBy);
response.setContentType("application/pdf");
JasperExportManager.exportReportToPdfStream(jasperPrint, response.getOutputStream());
}
// Klinik Utama Bintaro
@RequestMapping(value = {"/bukti-layanan-farmasi-bintaro/{norec}/{user}"}, method = {RequestMethod.GET})

View File

@ -782,6 +782,21 @@ public class ReportingDao {
return null;
}
public JasperPrint exportPdfTagihanPiutang(String noposting, String PrintBy) {
try (Connection conn = this.jdbcTemplate1.getDataSource().getConnection()) {
String path = jasperDirPath + "cetak_tagihan_pingutang.jrxml";
JasperReport jasperReport = JasperCompileManager.compileReport(path);
Map<String, Object> parameters = new HashMap<>();
parameters.put("noposting", noposting);
parameters.put("PrintBy", PrintBy);
return JasperFillManager.fillReport(jasperReport, parameters, conn);
} catch (Exception var17) {
LOG.error("Exception at exportPdfTagihanPiutang");
LOG.error(ReportingDao.class, var17);
}
return null;
}
// Klinik Utama Bintaro
public JasperPrint exportPdfBuktiLayananBintaro(String norec, String user) {

View File

@ -223,6 +223,10 @@ public class ReportingService {
return this.reportingDao.exportPdfBuktiOrderBarang(norec, pegawaiMengetahui, pegawaiMeminta, nipMengetahui, nipMeminta, jabatanMengetahui, jabatanMeminta, user);
}
public JasperPrint exportPdfTagihanPiutang(String noposting, String PrintBy) {
return this.reportingDao.exportPdfTagihanPiutang(noposting, PrintBy);
}
//Klinik Utama Bintaro