private void populateScreenFromData(EmergencyAttendanceBillingVo attendanceBillingVo) { clearScreen(); if (attendanceBillingVo == null) return; form.cmbIsPatientExempt().setValue(attendanceBillingVo.getIsPatientExempt()); form.cmbExemptionReason().setValue(attendanceBillingVo.getExemptionReason()); form.txtExemptionReasonOther().setValue(attendanceBillingVo.getExemptionReasonOther()); form.cmbPaymentMade().setValue(attendanceBillingVo.getPaymentMade()); form.cmbPaymentType().setValue(attendanceBillingVo.getPaymentType()); form.intInvoiceAmount().setValue(attendanceBillingVo.getInvoiceAmount()); form.cmbReasonForNonPayment().setValue(attendanceBillingVo.getReasonForNonPayment()); form.cmbPaymentRefunded().setValue(attendanceBillingVo.getPaymentRefunded()); }
public EmergencyAttendanceBillingVo getAttendanceBillingByEmergencyAttendance(EmergencyAttendanceRefVo emergencyAttendanceRef) { if (emergencyAttendanceRef == null || emergencyAttendanceRef.getID_EmergencyAttendance() == null) { throw new CodingRuntimeException("Cannot get EmergencyAttendanceBillingVo on null Id for EmergencyAttendance "); } DomainFactory factory = getDomainFactory(); StringBuffer hql = new StringBuffer(); hql.append("select emergeAttBilling from EmergencyAttendanceBilling as emergeAttBilling left join emergeAttBilling.emergencyAttendence as emergeAtt where (emergeAtt.id = :emergAttID) "); List<?> list = factory.find(hql.toString(), new String[] { "emergAttID" }, new Object[] { emergencyAttendanceRef.getID_EmergencyAttendance() }); if (list!=null && list.size()>0) { return EmergencyAttendanceBillingVoAssembler.create((EmergencyAttendanceBilling) list.get(0)); } return null; }
private void populateScreenFromData(EmergencyAttendanceBillingVo attendanceBillingVo) { clearScreen(); if (attendanceBillingVo == null) return; form.cmbIsPatientExempt().setValue(attendanceBillingVo.getIsPatientExempt()); form.cmbExemptionReason().setValue(attendanceBillingVo.getExemptionReason()); form.txtExemptionReasonOther().setValue(attendanceBillingVo.getExemptionReasonOther()); form.cmbPaymentMade().setValue(attendanceBillingVo.getPaymentMade()); form.cmbPaymentType().setValue(attendanceBillingVo.getPaymentType()); form.cmbInvoiceAmount().setValue(attendanceBillingVo.getInvoiceAmount()); //WDEV-22795 form.cmbReasonForNonPayment().setValue(attendanceBillingVo.getReasonForNonPayment()); form.cmbPaymentRefunded().setValue(attendanceBillingVo.getPaymentRefunded()); }
public void saveAttendance(EmergencyAttendanceBillingVo invoiceBilling, ChartRequestedVo chartRequested, EmergencyAttendanceNonInsuranceHealthCoverVo insuranceDetails) //WDEV-22956 { //WDEV-22956 form.getLocalContext().setInvoiceBillingToSave(invoiceBilling); form.getLocalContext().setChartRequestToSave(chartRequested); form.getLocalContext().setInsuranceDetailsToSave(insuranceDetails); form.getLocalContext().setIsSkippedTriage(null);//WDEV-17248 String[] uiErrors = getUIErrors(); if (uiErrors != null) { engine.showErrors(uiErrors); return; } if (form.getLocalContext().getSelectedEmergencyEpisodeIsNotNull() && form.getLocalContext().getSelectedRecordIsNotNull()) // wdev-14420 { if (save()) { form.getLocalContext().setSelectedEvent(EmergencyAttendanceEvent.SAVE); form.fireCustomControlValueChanged(); } } else engine.open(form.getForms().Emergency.SendToAreaDialog, new Object[] {Boolean.FALSE}); }
public EmergencyAttendanceBillingVo getAttendanceBillingByEmergencyAttendance(EmergencyAttendanceRefVo emergencyAttendanceRef) { if (emergencyAttendanceRef == null || emergencyAttendanceRef.getID_EmergencyAttendance() == null) { throw new CodingRuntimeException("Cannot get EmergencyAttendanceBillingVo on null Id for EmergencyAttendance "); } DomainFactory factory = getDomainFactory(); StringBuffer hql = new StringBuffer(); hql.append("select emergeAttBilling from EmergencyAttendanceBilling as emergeAttBilling left join emergeAttBilling.emergencyAttendence as emergeAtt where (emergeAtt.id = :emergAttID and (emergeAtt.isRIE is null or emergeAtt.isRIE = 0)) "); //WDEV-22956 List<?> list = factory.find(hql.toString(), new String[] { "emergAttID" }, new Object[] { emergencyAttendanceRef.getID_EmergencyAttendance() }); if (list!=null && list.size()>0) { return EmergencyAttendanceBillingVoAssembler.create((EmergencyAttendanceBilling) list.get(0)); } return null; }
public EmergencyAttendanceBillingVo getAttendanceBilling(EmergencyAttendanceBillingRefVo attendanceBillingRef) { if (attendanceBillingRef == null || attendanceBillingRef.getID_EmergencyAttendanceBilling() == null) { throw new CodingRuntimeException("Cannot get EmergencyAttendanceBillingVo on null Id "); } DomainFactory factory = getDomainFactory(); EmergencyAttendanceBilling domainEmergAttBilling = (EmergencyAttendanceBilling) factory.getDomainObject(EmergencyAttendanceBilling.class, attendanceBillingRef.getID_EmergencyAttendanceBilling()); return EmergencyAttendanceBillingVoAssembler.create(domainEmergAttBilling); }
public EmergencyAttendanceBillingVo save(EmergencyAttendanceBillingVo attendanceBillingToSave) throws ims.domain.exceptions.StaleObjectException, ims.domain.exceptions.UniqueKeyViolationException { if (attendanceBillingToSave == null ) { throw new CodingRuntimeException("Cannot get EmergencyAttendanceBillingVo on null Id "); } DomainFactory factory = getDomainFactory(); EmergencyAttendanceBilling domainEmergAttBilling = EmergencyAttendanceBillingVoAssembler.extractEmergencyAttendanceBilling(factory,attendanceBillingToSave); factory.save(domainEmergAttBilling); return EmergencyAttendanceBillingVoAssembler.create(domainEmergAttBilling); }
protected void onCcInsuranceDetailsValueChanged() throws PresentationLogicException { if( EmergencyAttendanceEvent.SAVE.equals(form.lyrEmergencyAttendance().tabInsuranceDetails().ccInsuranceDetails().getSelectedEvent()) || EmergencyAttendanceEvent.CANCEL.equals(form.lyrEmergencyAttendance().tabInsuranceDetails().ccInsuranceDetails().getSelectedEvent())) { form.lyrEmergencyAttendance().tabInsuranceDetails().ccInsuranceDetails().resetSelectedEvent(); open(); form.getLocalContext().setIsNewAttendanceInstance(null); //WDEV-22801 return; } //WDEV-22956 if (EmergencyAttendanceEvent.FINISH_SAVE.equals(form.lyrEmergencyAttendance().tabInsuranceDetails().ccInsuranceDetails().getSelectedEvent())) { form.lyrEmergencyAttendance().tabInsuranceDetails().ccInsuranceDetails().resetSelectedEvent(); EmergencyAttendanceBillingVo invoiceBilling = null; if (form.lyrEmergencyAttendance().tabInvoices().isHeaderVisible()) { invoiceBilling = form.lyrEmergencyAttendance().tabInvoices().ccInvoicesBilling().getValue(); } ChartRequestedVo chartRequested = null; if (form.lyrEmergencyAttendance().tabChart().isHeaderVisible()) { chartRequested = form.lyrEmergencyAttendance().tabChart().ccChatRequested().getValue(); } EmergencyAttendanceNonInsuranceHealthCoverVo insuranceDetails = form.lyrEmergencyAttendance().tabInsuranceDetails().ccInsuranceDetails().getValue(); form.lyrEmergencyAttendance().tabAttDet().ccAttendanceDetails().saveAttendance(invoiceBilling, chartRequested, insuranceDetails); } form.lyrEmergencyAttendance().tabInsuranceDetails().ccInsuranceDetails().resetSelectedEvent(); FormMode insurancedetailsmode = form.lyrEmergencyAttendance().tabInsuranceDetails().ccInsuranceDetails().getMode(); form.setMode(insurancedetailsmode); }
public void setValue(EmergencyAttendanceBillingVo attendanceBilling) { form.getLocalContext().setcurrentAttendanceBilling(attendanceBilling); populateScreenFromData(form.getLocalContext().getcurrentAttendanceBilling()); }
public EmergencyAttendanceBillingVo getAttendanceBillingByEmergencyAttendance(EmergencyAttendanceRefVo emergencyAttendanceRef) { IEmergencyHelper impl = (IEmergencyHelper)getDomainImpl(EmergencyHelper.class); return impl.getAttendanceBillingByEmergencyAttendance(emergencyAttendanceRef); }
public ims.emergency.vo.EmergencyAttendanceBillingVo getAttendanceBilling(ims.core.admin.vo.EmergencyAttendanceBillingRefVo attendanceBillingRef) { IEmergencyHelper impl = (IEmergencyHelper)getDomainImpl(EmergencyHelper.class); return impl.getAttendanceBilling(attendanceBillingRef); }
public ims.emergency.vo.EmergencyAttendanceBillingVo getAttendanceBillingByEmergencyAttendance(ims.core.admin.vo.EmergencyAttendanceRefVo emergencyAttendanceRef) { IEmergencyHelper impl = (IEmergencyHelper)getDomainImpl(EmergencyHelper.class); return impl.getAttendanceBillingByEmergencyAttendance(emergencyAttendanceRef); }
private void updateControlState() //WDEV-22796 { EmergencyAttendanceBillingVo currentEmergAttBilling = (form.getLocalContext().getAttendanceDetailsRefIsNotNull() ? domain.getAttendanceBillingByEmergencyAttendance(form.getLocalContext().getAttendanceDetailsRef()) : null); form.btnNew().setVisible(FormMode.VIEW.equals(form.getMode()) && currentEmergAttBilling == null && form.getLocalContext().getAttendanceDetailsRefIsNotNull()); //WDEV-22956 form.btnEdit().setVisible(FormMode.VIEW.equals(form.getMode()) && currentEmergAttBilling != null); form.cmbIsPatientExempt().setRequired(true); form.cmbIsPatientExempt().setEnabled(FormMode.EDIT.equals(form.getMode())); EDAttendanceControlsConfigVoCollection attendanceControlsConfig = domain.getEDAttendanceControlsConfig(EDAttendenceControlType.INV_BILL_CONTROLS); for (int i = 0; attendanceControlsConfig != null && i < attendanceControlsConfig.size(); i++) { EDAttendanceControlsConfigVo controlConfig = attendanceControlsConfig.get(i); if (EXEMPTION_REASON.equals(controlConfig.getControlIMSID())) { form.lblExemptionReason().setVisible(controlConfig.getIsVisible()); form.cmbExemptionReason().setVisible(controlConfig.getIsVisible()); form.cmbExemptionReason().setEnabled(FormMode.EDIT.equals(form.getMode()) && controlConfig.getIsEditable() && !YesNo.NO.equals(form.cmbIsPatientExempt().getValue())); form.cmbExemptionReason().setRequired(controlConfig.getIsRequired() || YesNo.YES.equals(form.cmbIsPatientExempt().getValue())); } else if (EXEMPTION_REASON_OTHER.equals(controlConfig.getControlIMSID())) { form.lblExemptionReasonOther().setVisible(controlConfig.getIsVisible()); form.txtExemptionReasonOther().setVisible(controlConfig.getIsVisible()); form.txtExemptionReasonOther().setEnabled(FormMode.EDIT.equals(form.getMode()) && !YesNo.NO.equals(form.cmbIsPatientExempt().getValue()) && (controlConfig.getIsEditable() || ExemptionReason.EXEMPT_OTHER.equals(form.cmbExemptionReason().getValue()))); form.txtExemptionReasonOther().setRequired(controlConfig.getIsRequired() || ExemptionReason.EXEMPT_OTHER.equals(form.cmbExemptionReason().getValue())); } else if (PAYMENT_MADE.equals(controlConfig.getControlIMSID())) { form.lblPaymentMade().setVisible(controlConfig.getIsVisible()); form.cmbPaymentMade().setVisible(controlConfig.getIsVisible()); form.cmbPaymentMade().setEnabled(FormMode.EDIT.equals(form.getMode()) && controlConfig.getIsEditable() && !YesNo.YES.equals(form.cmbIsPatientExempt().getValue())); form.cmbPaymentMade().setRequired(controlConfig.getIsRequired() || YesNo.NO.equals(form.cmbIsPatientExempt().getValue())); } else if (PAYMENT_TYPE.equals(controlConfig.getControlIMSID())) { form.lblPaymentType().setVisible(controlConfig.getIsVisible()); form.cmbPaymentType().setVisible(controlConfig.getIsVisible()); form.cmbPaymentType().setEnabled(FormMode.EDIT.equals(form.getMode()) && controlConfig.getIsEditable() && !YesNo.NO.equals(form.cmbPaymentMade().getValue())); form.cmbPaymentType().setRequired(controlConfig.getIsRequired() || (YesNo.NO.equals(form.cmbIsPatientExempt().getValue()) && !YesNo.NO.equals(form.cmbPaymentMade().getValue())));//WDEV-17160 } else if (INVOICE_AMOUNT.equals(controlConfig.getControlIMSID())) { form.lblInvoiceAmount().setVisible(controlConfig.getIsVisible()); //WDEV-22795 form.cmbInvoiceAmount().setVisible(controlConfig.getIsVisible()); form.cmbInvoiceAmount().setEnabled(FormMode.EDIT.equals(form.getMode()) && controlConfig.getIsEditable() && !YesNo.YES.equals(form.cmbIsPatientExempt().getValue())); form.cmbInvoiceAmount().setRequired(controlConfig.getIsRequired() || (YesNo.NO.equals(form.cmbIsPatientExempt().getValue()) && !YesNo.NO.equals(form.cmbPaymentMade().getValue())));//WDEV-17160 } else if (REASON_FOR_NON_PAYMENT.equals(controlConfig.getControlIMSID())) { form.lblReasonForNonPayment().setVisible(controlConfig.getIsVisible()); form.cmbReasonForNonPayment().setVisible(controlConfig.getIsVisible()); form.cmbReasonForNonPayment().setEnabled(FormMode.EDIT.equals(form.getMode()) && controlConfig.getIsEditable() && !YesNo.YES.equals(form.cmbIsPatientExempt().getValue()) && !YesNo.YES.equals(form.cmbPaymentMade().getValue())); //WDEV-22955 form.cmbReasonForNonPayment().setRequired(controlConfig.getIsRequired() || (YesNo.NO.equals(form.cmbIsPatientExempt().getValue()) && YesNo.NO.equals(form.cmbPaymentMade().getValue())) && !YesNo.YES.equals(form.cmbPaymentMade().getValue())); } else if (PAYMENT_REFUNDED.equals(controlConfig.getControlIMSID())) { form.lblPaymentRefunded().setVisible(controlConfig.getIsVisible()); form.cmbPaymentRefunded().setVisible(controlConfig.getIsVisible()); form.cmbPaymentRefunded().setEnabled(FormMode.EDIT.equals(form.getMode()) && controlConfig.getIsEditable() && !YesNo.YES.equals(form.cmbIsPatientExempt().getValue())); form.cmbPaymentRefunded().setRequired(controlConfig.getIsRequired()); } } //WDEV-22956 boolean SVUH_FUNCTIONALITY = ConfigFlag.UI.SVUH_MANDATORY_DEMOGRAPHIC_ATTRIBUTES.getValue(); form.btnSave().setVisible(FormMode.EDIT.equals(form.getMode()) && (!Boolean.TRUE.equals(form.getLocalContext().getIsNewAttendance()) || !SVUH_FUNCTIONALITY || Boolean.TRUE.equals(form.getLocalContext().getIsFinalTab()))); form.btnCancel().setVisible(FormMode.EDIT.equals(form.getMode()) && (!Boolean.TRUE.equals(form.getLocalContext().getIsNewAttendance()) || !SVUH_FUNCTIONALITY || Boolean.TRUE.equals(form.getLocalContext().getIsFinalTab()))); form.btnNext().setVisible(FormMode.EDIT.equals(form.getMode()) && !form.btnSave().isVisible()); }
public EmergencyAttendanceBillingVo getValue() { return populateDataFromScreen(form.getLocalContext().getcurrentAttendanceBilling()); }
@Override //WDEV-16673 protected void onCcChatRequestedValueChanged() throws PresentationLogicException { if (EmergencyAttendanceEvent.SAVE.equals(form.lyrEmergencyAttendance().tabChart().ccChatRequested().getSelectedEvent())) //WDEV-22801 { form.lyrEmergencyAttendance().tabChart().ccChatRequested().resetSelectedEvent(); if (!form.lyrEmergencyAttendance().tabInsuranceDetails().isHeaderVisible()) //WDEV-22901 { form.getLocalContext().setIsNewAttendanceInstance(null); } //WDEV-22801 if (Boolean.TRUE.equals(form.getLocalContext().getIsNewAttendanceInstance())) { if (form.lyrEmergencyAttendance().tabInsuranceDetails().isHeaderVisible()) { form.lyrEmergencyAttendance().showtabInsuranceDetails(); form.lyrEmergencyAttendance().tabInsuranceDetails().ccInsuranceDetails().newInstance(false); //WDEV-22956 } } else { open(); } return; } else if (EmergencyAttendanceEvent.CANCEL.equals(form.lyrEmergencyAttendance().tabChart().ccChatRequested().getSelectedEvent())) //WDEV-22801 { form.lyrEmergencyAttendance().tabChart().ccChatRequested().resetSelectedEvent(); open(); form.getLocalContext().setIsNewAttendanceInstance(null); return; } //WDEV-22956 if (EmergencyAttendanceEvent.NEXT.equals(form.lyrEmergencyAttendance().tabChart().ccChatRequested().getSelectedEvent()) && form.lyrEmergencyAttendance().tabInsuranceDetails().isHeaderVisible()) { form.lyrEmergencyAttendance().showtabInsuranceDetails(); form.lyrEmergencyAttendance().tabInsuranceDetails().ccInsuranceDetails().newInstance(true); } if (EmergencyAttendanceEvent.FINISH_SAVE.equals(form.lyrEmergencyAttendance().tabChart().ccChatRequested().getSelectedEvent())) { form.lyrEmergencyAttendance().tabChart().ccChatRequested().resetSelectedEvent(); EmergencyAttendanceBillingVo invoiceBilling = null; if (form.lyrEmergencyAttendance().tabInvoices().isHeaderVisible()) { invoiceBilling = form.lyrEmergencyAttendance().tabInvoices().ccInvoicesBilling().getValue(); } ChartRequestedVo chartRequested = form.lyrEmergencyAttendance().tabChart().ccChatRequested().getValue(); form.lyrEmergencyAttendance().tabAttDet().ccAttendanceDetails().saveAttendance(invoiceBilling, chartRequested, null); } form.lyrEmergencyAttendance().tabChart().ccChatRequested().resetSelectedEvent(); FormMode chartReqMode = form.lyrEmergencyAttendance().tabChart().ccChatRequested().getMode(); form.setMode(chartReqMode); }
@Override //WDEV-16673 protected void onCcInvoicesBillingValueChanged() throws PresentationLogicException { if (EmergencyAttendanceEvent.SAVE.equals(form.lyrEmergencyAttendance().tabInvoices().ccInvoicesBilling().getSelectedEvent())) //WDEV-22801 { form.lyrEmergencyAttendance().tabInvoices().ccInvoicesBilling().resetSelectedEvent(); if (!form.lyrEmergencyAttendance().tabChart().isHeaderVisible() && !form.lyrEmergencyAttendance().tabInsuranceDetails().isHeaderVisible() ) //WDEV-22901 { form.getLocalContext().setIsNewAttendanceInstance(null); } //WDEV-22801 if (Boolean.TRUE.equals(form.getLocalContext().getIsNewAttendanceInstance())) { if (form.lyrEmergencyAttendance().tabChart().isHeaderVisible()) { form.lyrEmergencyAttendance().showtabChart(); form.lyrEmergencyAttendance().tabChart().ccChatRequested().newInstance(false); //WDEV-22956 } else if (form.lyrEmergencyAttendance().tabInsuranceDetails().isHeaderVisible()) { form.lyrEmergencyAttendance().showtabInsuranceDetails(); form.lyrEmergencyAttendance().tabInsuranceDetails().ccInsuranceDetails().newInstance(false); //WDEV-22956 } } else { open(); } return; } else if (EmergencyAttendanceEvent.CANCEL.equals(form.lyrEmergencyAttendance().tabInvoices().ccInvoicesBilling().getSelectedEvent())) //WDEV-22801 { form.lyrEmergencyAttendance().tabInvoices().ccInvoicesBilling().resetSelectedEvent(); open(); form.getLocalContext().setIsNewAttendanceInstance(null); return; } //WDEV-22956 if (EmergencyAttendanceEvent.NEXT.equals(form.lyrEmergencyAttendance().tabInvoices().ccInvoicesBilling().getSelectedEvent()) && Boolean.TRUE.equals(form.getLocalContext().getIsNewAttendanceInstance())) { if (form.lyrEmergencyAttendance().tabChart().isHeaderVisible()) { form.lyrEmergencyAttendance().showtabChart(); form.lyrEmergencyAttendance().tabChart().ccChatRequested().newInstance(true); } else if (form.lyrEmergencyAttendance().tabInsuranceDetails().isHeaderVisible()) { form.lyrEmergencyAttendance().showtabInsuranceDetails(); form.lyrEmergencyAttendance().tabInsuranceDetails().ccInsuranceDetails().newInstance(true); } } if (EmergencyAttendanceEvent.FINISH_SAVE.equals(form.lyrEmergencyAttendance().tabInvoices().ccInvoicesBilling().getSelectedEvent())) { form.lyrEmergencyAttendance().tabInvoices().ccInvoicesBilling().resetSelectedEvent(); EmergencyAttendanceBillingVo invoiceBilling = form.lyrEmergencyAttendance().tabInvoices().ccInvoicesBilling().getValue(); form.lyrEmergencyAttendance().tabAttDet().ccAttendanceDetails().saveAttendance(invoiceBilling, null, null); } form.lyrEmergencyAttendance().tabInvoices().ccInvoicesBilling().resetSelectedEvent(); FormMode invoiceBillingMode = form.lyrEmergencyAttendance().tabInvoices().ccInvoicesBilling().getMode(); form.setMode(invoiceBillingMode); }
public EmergencyAttendanceBillingVo getAttendanceBillingByEmergencyAttendance(EmergencyAttendanceRefVo emergencyAttendanceRef);
public EmergencyAttendanceBillingVo getAttendanceBilling(ims.core.admin.vo.EmergencyAttendanceBillingRefVo attendanceBillingRef);