Update PelayananPasienServiceImpl.java

Penambahan message mandatori parameter nomor registrasi
This commit is contained in:
Salman Manoe 2023-08-22 07:33:43 +07:00
parent 350ed2a2b8
commit d7803b01a7

View File

@ -2290,6 +2290,8 @@ public class PelayananPasienServiceImpl extends BaseVoServiceImpl implements Pel
public boolean isValidVoucher(String kodeVoucher, String noRegistrasi) {
if (kodeVoucher.isEmpty())
throw new ServiceVOException("Kode voucher harus diisi");
if (noRegistrasi.isEmpty())
throw new ServiceVOException("Nomor registrasi harus diisi");
VoucherPaket voucher = voucherPaketDao.findByKode(kodeVoucher);
if (CommonUtil.isNullOrEmpty(voucher))
throw new ServiceVOException("Kode voucher tidak ditemukan");