private void refreshSearchCriteria() { IPandOPSearchCriteriaVo voCriteria = form.getGlobalContext().getUKSHOutPatientWardViewSearchCriteria(); form.cmbHospital().setValue((LocationLiteVo) voCriteria.getHospital()); form.dteDate().setValue(voCriteria.getDate()); if(form.cmbHospital().getValue() != null && form.dteDate().getValue() != null) loadClinics(voCriteria.getClinicIsNotNull()); form.cmbClinic().setValue((SessionShortVo) voCriteria.getClinic()); search(); //WDEV-13354 if(voCriteria.getWasTimerOnIsNotNull() && voCriteria.getWasTimerOn()) { form.getLocalContext().setWasTimerEnabled(true); toggleTimer(false); } }
private IPandOPSearchCriteriaVo populateSearchFilter(IPandOPSearchCriteriaVo filterVo) { if (form.cmbHospital().getValue() != null) filterVo.setHospital(form.cmbHospital().getValue()); if (form.cmbClinic().getValue() != null) filterVo.setClinic(form.cmbClinic().getValue()); if (form.dteDate().getValue() != null) filterVo.setDate(form.dteDate().getValue()); //WDEV-13354 filterVo.setWasTimerOn(form.getLocalContext().getWasTimerEnabled()); return filterVo; }
private void refreshSearchCriteria(IPandOPSearchCriteriaVo searchCriteria) { if (searchCriteria == null) return; form.cmbHospital().setValue((LocationLiteVo) searchCriteria.getHospital()); form.dteDate().setValue(searchCriteria.getDate()); if (form.cmbHospital().getValue() != null && form.dteDate().getValue() != null) loadClinics(searchCriteria.getClinicIsNotNull()); form.cmbClinic().setValue((SessionShortVo) searchCriteria.getClinic()); form.cmbAppOutcome().setValue(searchCriteria.getApptOutcome()); form.cmbAction().setValue(searchCriteria.getAppointmentAction()); form.chkComplete().setValue(searchCriteria.getComplete()); form.dteFrom().setValue(searchCriteria.getApptDateFrom()); form.dteTo().setValue(searchCriteria.getApptDateTo()); search(); }
private void refreshSearchCriteria() { IPandOPSearchCriteriaVo voCriteria = form.getGlobalContext().Core.getUKSHInPatientWardViewSearchCriteria(); form.cmbHospital().setValue((LocationLiteVo) voCriteria.getHospital()); if(form.cmbHospital().getValue() != null) loadWards(); else form.cmbWard().clear(); //wdev-12482 form.cmbWard().setValue((LocationLiteVo) voCriteria.getWard()); form.ccHCP().setValue((IMos)voCriteria.getConsultant()); search(); }
private IPandOPSearchCriteriaVo populateSearchFilter(IPandOPSearchCriteriaVo filterVo) { if (form.cmbHospital().getValue() != null) filterVo.setHospital(form.cmbHospital().getValue()); if (form.cmbWard().getValue() != null) filterVo.setWard(form.cmbWard().getValue()); if (form.ccHCP().getValue() != null) filterVo.setConsultant((IMos)form.ccHCP().getValue()); return filterVo; }
private void search() { //WDEV-13354 form.imbAutoRefresh().setEnabled(false); if ( ! validateSearch()) return; IPandOPSearchCriteriaVo filterVo = new IPandOPSearchCriteriaVo(); filterVo = populateSearchFilter(filterVo); if (filterVo ==null) return; form.getLocalContext().setbDNACalled(false); form.getGlobalContext().setUKSHOutPatientWardViewSearchCriteria(filterVo); form.grdResults().getRows().clear(); form.getContextMenus().Clinical.hideAllOPClinicViewListMenuItems(); OutpatientEpisodeWithICPInfoVoCollection list = domain.listOPEpisodes(filterVo); if (list == null || list.size() == 0) { engine.showMessage("No records match your search criteria.", "No data found", MessageButtons.OK, MessageIcon.WARNING); return; } //WDEV-11771 - starts here list.sort(OutpatientEpisodeWithICPInfoVo.getTimeComparator(SortOrder.ASCENDING)); form.getLocalContext().setSortOrderTime(SortOrder.DESCENDING); //WDEV-11771 - ends here populateGrid(list); //WDEV-13354 form.imbAutoRefresh().setEnabled(true); }
private IPandOPSearchCriteriaVo populateSearchFilter(IPandOPSearchCriteriaVo filterVo) { if (form.cmbHospital().getValue() != null) filterVo.setHospital(form.cmbHospital().getValue()); if (form.cmbClinic().getValue() != null) filterVo.setClinic(form.cmbClinic().getValue()); if (form.dteDate().getValue() != null) filterVo.setDate(form.dteDate().getValue()); if (form.cmbAppOutcome().getValue() != null) filterVo.setApptOutcome(form.cmbAppOutcome().getValue()); if (form.cmbAction().getValue() != null) filterVo.setAppointmentAction(form.cmbAction().getValue()); if (form.dteFrom().getValue() != null) filterVo.setApptDateFrom(form.dteFrom().getValue()); if (form.dteTo().getValue() != null) filterVo.setApptDateTo(form.dteTo().getValue()); filterVo.setComplete(form.chkComplete().getValue()); return filterVo; }
private void search() { //WDEV-13354 form.imbAutoRefresh().setEnabled(false); if ( ! validateSearch()) return; IPandOPSearchCriteriaVo filterVo = new IPandOPSearchCriteriaVo(); filterVo = populateSearchFilter(filterVo); if (filterVo ==null) return; form.getLocalContext().setbDNACalled(false); form.getLocalContext().setbSeenByPreOp(false); form.getGlobalContext().setUKSHOutPatientWardViewSearchCriteria(filterVo); form.grdResults().getRows().clear(); form.getLocalContext().setSelectedRow(null); form.getContextMenus().Clinical.hideAllOPClinicViewListMenuItems(); OutpatientEpisodeWithICPInfoVoCollection list = domain.listOPEpisodes(filterVo); if (list == null || list.size() == 0) { engine.showMessage("No records match your search criteria.", "No Data Found", MessageButtons.OK, MessageIcon.WARNING); return; } //WDEV-11771 - starts here list.sort(OutpatientEpisodeWithICPInfoVo.getTimeComparator(SortOrder.ASCENDING)); form.getLocalContext().setSortOrderTime(SortOrder.DESCENDING); //WDEV-11771 - ends here populateGrid(list); //WDEV-13354 form.imbAutoRefresh().setEnabled(true); }
private IPandOPSearchCriteriaVo populateSearchFilter(IPandOPSearchCriteriaVo filterVo) { if (form.cmbHospital().getValue() != null) filterVo.setHospital(form.cmbHospital().getValue()); if (form.cmbClinic().getValue() != null) filterVo.setClinic(form.cmbClinic().getValue()); if (form.dteDate().getValue() != null) filterVo.setDate(form.dteDate().getValue()); if (form.qmbService().getValue() != null) filterVo.setService(form.qmbService().getValue()); if (form.ccListOwner().getValue() != null) { HcpLiteVoCollection hcpCollection = new HcpLiteVoCollection(); hcpCollection.add(form.ccListOwner().getValue() instanceof HcpLiteVo ? (HcpLiteVo) form.ccListOwner().getValue() : null); filterVo.setListOwners(hcpCollection); } else if (form.getGlobalContext().Scheduling.getSelectedHCPs() != null && form.getGlobalContext().Scheduling.getSelectedHCPs().size() > 0) { filterVo.setListOwners(form.getGlobalContext().Scheduling.getSelectedHCPs()); } filterVo.setListType(form.cmbListType().getValue()); //wdev-19419 filterVo.setOutPatientLocation(form.cmbOutpatientLocation().getValue()); //wdev-19503 //WDEV-13354 filterVo.setWasTimerOn(form.getLocalContext().getWasTimerEnabled()); return filterVo; }
private void refreshSearchCriteria(IPandOPSearchCriteriaVo searchCriteria) { if (searchCriteria == null) return; form.cmbHospital().setValue((LocationLiteVo) searchCriteria.getHospital()); form.dteDate().setValue(searchCriteria.getDate()); if (form.cmbHospital().getValue() != null && form.dteDate().getValue() != null) loadClinics(searchCriteria.getClinicIsNotNull()); if (searchCriteria.getServiceIsNotNull()) { form.qmbService().newRow(searchCriteria.getService(), searchCriteria.getService().getServiceName()); form.qmbService().setValue(searchCriteria.getService()); } form.cmbClinic().setValue((SessionShortVo) searchCriteria.getClinic()); form.cmbAppOutcome().setValue(searchCriteria.getApptOutcome()); form.cmbAction().setValue(searchCriteria.getAppointmentAction()); form.chkComplete().setValue(searchCriteria.getComplete()); form.dteFrom().setValue(searchCriteria.getApptDateFrom()); form.dteTo().setValue(searchCriteria.getApptDateTo()); if (searchCriteria.getListOwners() != null && searchCriteria.getListOwners().size() > 0) { if (searchCriteria.getListOwners().size() == 1) { form.ccListOwner().setValue(searchCriteria.getListOwners().get(0)); } else { form.getGlobalContext().Scheduling.setSelectedHCPs(searchCriteria.getListOwners()); populateListOwnersLabel(searchCriteria.getListOwners()); } } search(); }
private void search() { if (!validateSearch()) return; form.dynGrdResults().getRows().clear(); IPandOPSearchCriteriaVo filterVo = new IPandOPSearchCriteriaVo(); filterVo = populateSearchFilter(filterVo); form.getGlobalContext().Clinical.setClinicListActionSummarySearchCriteria(filterVo); OutpatientEpisodeWithICPInfoVoCollection list = domain.listOPEpisodes(filterVo); if (list == null || list.size() == 0) { engine.showMessage("No records match your search criteria.", "No data found", MessageButtons.OK, MessageIcon.WARNING); form.lblTotal().setValue("Total: 0"); updateControlsState(); return; } boolean hasItemWithFollowUpApptDetailsF = hasItemWithFollowUpApptDetailsForBookAction(list); boolean hasItemWithComments = hasItemWithOutcomeComments(list); list.sort(OutpatientEpisodeWithICPInfoVo.getTimeComparator(SortOrder.ASCENDING)); form.lblTotal().setValue("Total: " + list.size()); initialiseDynamicGrid(hasItemWithFollowUpApptDetailsF, hasItemWithComments); populateGrid(list); updateControlsState(); }
/** * WDEV-12481 * Function used to retrieve the InpatientEpisodes and associated ICP info for the referral * the inpatient episode was created for. */ public InpatientEpisodeWithICPInfoVoCollection listIPEpisodes(IPandOPSearchCriteriaVo searchCriteria) { ArrayList<String> markers = new ArrayList<String>(); ArrayList<Object> values = new ArrayList<Object>(); StringBuffer querry = new StringBuffer(); querry.append("select inpatient, icp, context "); querry.append("from PatientICP as icp right join icp.careContext as context right join context.pasEvent as pas1, "); querry.append("InpatientEpisode as inpatient left join inpatient.pasEvent as inppas left join inppas.location as inploc "); querry.append("where pas1.id = inppas.id"); if (searchCriteria.getConsultantIsNotNull() && searchCriteria.getConsultant().getIMosHcpId() != null) { querry.append(" and inppas.consultant.id = :CONS"); markers.add("CONS"); values.add(searchCriteria.getConsultant().getIMosHcpId()); } if (searchCriteria.getWardIsNotNull()) { querry.append(" and inploc.id = :WARD"); markers.add("WARD"); values.add(searchCriteria.getWard().getID_Location()); } else if (searchCriteria.getHospitalIsNotNull()) { querry.append(" and inploc.parentLocation.id = :HOSPITAL"); markers.add("HOSPITAL"); values.add(searchCriteria.getHospital().getID_Location()); } //WDEV-12965 querry.append(" and icp.completedDateTime is null"); @SuppressWarnings("rawtypes") List results = getDomainFactory().find(querry.toString(), markers, values); // Inpatient Episode InpatientEpisodeWithICPInfoVoCollection voColl = new InpatientEpisodeWithICPInfoVoCollection(); @SuppressWarnings("rawtypes") Iterator iterator = results.iterator(); // Declare the results while (iterator.hasNext()) { Object[] next = (Object[]) iterator.next(); // Create an Inpatient Episode with ICP Info from Object[] if (next[0] instanceof InpatientEpisode) { InpatientEpisodeWithICPInfoVo inpatientEpisodeVo = InpatientEpisodeWithICPInfoVoAssembler.create((InpatientEpisode) next[0]); // Add ICP Info if needed if (inpatientEpisodeVo != null && next[1] instanceof PatientICP) inpatientEpisodeVo.setICPInfo(PatientICPLiteVoAssembler.create((PatientICP) next[1])); // Add CareContext if (inpatientEpisodeVo != null && next[2] instanceof CareContext) inpatientEpisodeVo.setCareContext(CareContextListVoAssembler.create((CareContext) next[2])); voColl.add(inpatientEpisodeVo); } } if (voColl.size() > 0) return voColl; return null; }
private void refreshSearchCriteria() { IPandOPSearchCriteriaVo voCriteria = form.getGlobalContext().getUKSHOutPatientWardViewSearchCriteria(); form.cmbHospital().setValue((LocationLiteVo) voCriteria.getHospital()); if( form.cmbHospital().getValue() != null) //wdev-19503 populateOutpatientLocationCombo(); if (voCriteria.getServiceIsNotNull()) { form.qmbService().newRow(voCriteria.getService(), voCriteria.getService().getServiceName()); form.qmbService().setValue(voCriteria.getService()); } form.dteDate().setValue(voCriteria.getDate()); if(form.cmbHospital().getValue() != null && form.dteDate().getValue() != null) loadClinics(voCriteria.getClinicIsNotNull()); form.cmbClinic().setValue((SessionShortVo) voCriteria.getClinic()); if (voCriteria.getListOwners() != null && voCriteria.getListOwners().size() > 0) { if (voCriteria.getListOwners().size() == 1) { form.ccListOwner().setValue(voCriteria.getListOwners().get(0)); } else { form.getGlobalContext().Scheduling.setSelectedHCPs(voCriteria.getListOwners()); populateListOwnersLabel(voCriteria.getListOwners()); } } form.cmbListType().setValue(voCriteria.getListType()); //wdev-19419 form.cmbOutpatientLocation().setValue(voCriteria.getOutPatientLocation()); //wdev-19503 search(); //WDEV-13354 if(voCriteria.getWasTimerOnIsNotNull() && voCriteria.getWasTimerOn()) { form.getLocalContext().setWasTimerEnabled(true); toggleTimer(false); } }
private IPandOPSearchCriteriaVo populateSearchFilter(IPandOPSearchCriteriaVo filterVo) { if (form.cmbHospital().getValue() != null) filterVo.setHospital(form.cmbHospital().getValue()); if (form.cmbClinic().getValue() != null) filterVo.setClinic(form.cmbClinic().getValue()); if (form.dteDate().getValue() != null) filterVo.setDate(form.dteDate().getValue()); if (form.cmbAppOutcome().getValue() != null) filterVo.setApptOutcome(form.cmbAppOutcome().getValue()); if (form.cmbAction().getValue() != null) filterVo.setAppointmentAction(form.cmbAction().getValue()); if (form.dteFrom().getValue() != null) filterVo.setApptDateFrom(form.dteFrom().getValue()); if (form.dteTo().getValue() != null) filterVo.setApptDateTo(form.dteTo().getValue()); if (form.qmbService().getValue() != null) filterVo.setService(form.qmbService().getValue()); if (form.ccListOwner().getValue() != null) { HcpLiteVoCollection hcpCollection = new HcpLiteVoCollection(); hcpCollection.add(form.ccListOwner().getValue() instanceof HcpLiteVo ? (HcpLiteVo) form.ccListOwner().getValue() : null); filterVo.setListOwners(hcpCollection); } else if (form.getGlobalContext().Scheduling.getSelectedHCPs() != null && form.getGlobalContext().Scheduling.getSelectedHCPs().size() > 0) { filterVo.setListOwners(form.getGlobalContext().Scheduling.getSelectedHCPs()); } filterVo.setComplete(form.chkComplete().getValue()); return filterVo; }
private void search() { if (!validateSearch()) return; form.grdResults().getRows().clear(); IPandOPSearchCriteriaVo filterVo = new IPandOPSearchCriteriaVo(); filterVo = populateSearchFilter(filterVo); form.getGlobalContext().Clinical.setClinicListActionSummarySearchCriteria(filterVo); OutpatientEpisodeWithICPInfoVoCollection list = domain.listOPEpisodes(filterVo); if (list == null || list.size() == 0) { engine.showMessage("No records match your search criteria.", "No data found", MessageButtons.OK, MessageIcon.WARNING); form.lblTotal().setValue("Total: 0"); updateControlsState(); return; } list.sort(OutpatientEpisodeWithICPInfoVo.getTimeComparator(SortOrder.ASCENDING)); form.lblTotal().setValue("Total: " + list.size()); populateGrid(list); updateControlsState(); }