private void populateAreasCombo() { form.cmbArea().clear(); TrackingAreaShortVoCollection tempVoColl = domain.listTrackingAreas(engine.getCurrentLocation()); TrackingAreaShortVo overral = null; if( tempVoColl != null && tempVoColl.size() > 0 ) { for( int i = 0; i < tempVoColl.size();i++ ) { TrackingAreaShortVo tempTrVo = tempVoColl.get(i); if( tempTrVo != null && tempTrVo.getIsOverallViewIsNotNull() && Boolean.TRUE.equals(tempTrVo.getIsOverallView())) overral = tempTrVo; form.cmbArea().newRow(tempTrVo,tempTrVo.getAreaDisplayName()); } if( overral != null) form.cmbArea().setValue(overral); } }
private void initialiseareasCombo() { form.lyrWorklist().tabClinicianWorklist().cmbAreas().clear(); TrackingAreaShortVoCollection tempVoColl = domain.listTrackingAreas(engine.getCurrentLocation()); TrackingAreaShortVo overral = null; if( tempVoColl != null && tempVoColl.size() > 0 ) { for( int i = 0; i < tempVoColl.size();i++ ) { TrackingAreaShortVo tempTrVo = tempVoColl.get(i); if( tempTrVo != null && tempTrVo.getIsOverallViewIsNotNull() && Boolean.TRUE.equals(tempTrVo.getIsOverallView())) overral = tempTrVo; form.lyrWorklist().tabClinicianWorklist().cmbAreas().newRow(tempTrVo,tempTrVo.getAreaDisplayName()); } if( overral != null) form.lyrWorklist().tabClinicianWorklist().cmbAreas().setValue(overral); } }
private void populateAreasCombo() { form.cmbArea().clear(); TrackingAreaShortVoCollection tempVoColl = domain.listTrackingAreas(engine.getCurrentLocation()); TrackingAreaShortVo overral = null; if( tempVoColl != null && tempVoColl.size() > 0 ) { for( int i = 0; i < tempVoColl.size();i++ ) { TrackingAreaShortVo tempTrVo = tempVoColl.get(i); if( tempTrVo != null && tempTrVo.getIsOverallViewIsNotNull() && Boolean.TRUE.equals(tempTrVo.getIsOverallView())) overral = tempTrVo; form.cmbArea().newRow(tempTrVo,tempTrVo.getAreaDisplayName()); } if (form.getLocalContext().getSelectedAreaIsNotNull()) { form.cmbArea().setValue(form.getLocalContext().getSelectedArea()); } else if( overral != null) { form.cmbArea().setValue(overral); } } }
private void initialiseAreasTriageCombo() { form.lyrWorklist().tabTriageWorklist().cmbAreasForTriage().clear(); TrackingAreaShortVoCollection tempVoColl = domain.listTrackingAreas(engine.getCurrentLocation()); TrackingAreaShortVo overral = null; if (tempVoColl == null || tempVoColl.size() == 0) return; for (int i = 0; i < tempVoColl.size(); i++) { TrackingAreaShortVo tempTrVo = tempVoColl.get(i); if (tempTrVo != null && tempTrVo.getIsOverallViewIsNotNull() && Boolean.TRUE.equals(tempTrVo.getIsOverallView())) overral = tempTrVo; form.lyrWorklist().tabTriageWorklist().cmbAreasForTriage().newRow(tempTrVo, tempTrVo.getAreaDisplayName()); } if (overral != null) form.lyrWorklist().tabTriageWorklist().cmbAreasForTriage().setValue(overral); }
private void initialiseAreasClinicianCombo() { form.lyrWorklist().tabClinicianWorklist().cmbAreas().clear(); TrackingAreaShortVoCollection tempVoColl = domain.listTrackingAreas(engine.getCurrentLocation()); TrackingAreaShortVo overral = null; if( tempVoColl != null && tempVoColl.size() > 0 ) { for( int i = 0; i < tempVoColl.size();i++ ) { TrackingAreaShortVo tempTrVo = tempVoColl.get(i); if( tempTrVo != null && tempTrVo.getIsOverallViewIsNotNull() && Boolean.TRUE.equals(tempTrVo.getIsOverallView())) overral = tempTrVo; form.lyrWorklist().tabClinicianWorklist().cmbAreas().newRow(tempTrVo,tempTrVo.getAreaDisplayName()); } if( overral != null) form.lyrWorklist().tabClinicianWorklist().cmbAreas().setValue(overral); } }
private void populateAreasCombo() { form.cmbArea().clear(); TrackingAreaShortVoCollection tempVoColl = domain.listTrackingAreas(form.getLocalContext().getSelectedAreaIsNotNull() ? form.getLocalContext().getSelectedArea().getEDLocation() : (engine.getCurrentLocation() != null ? new LocationRefVo(engine.getCurrentLocation().getID(), 0) : null)); TrackingAreaShortVo overral = null; if( tempVoColl != null && tempVoColl.size() > 0 ) { for( int i = 0; i < tempVoColl.size();i++ ) { TrackingAreaShortVo tempTrVo = tempVoColl.get(i); if( tempTrVo != null && tempTrVo.getIsOverallViewIsNotNull() && Boolean.TRUE.equals(tempTrVo.getIsOverallView())) overral = tempTrVo; form.cmbArea().newRow(tempTrVo,tempTrVo.getAreaDisplayName()); } if( overral != null) form.cmbArea().setValue(overral); } }
protected void onFormOpen(Object[] args) throws ims.framework.exceptions.PresentationLogicException { initialize(args); if (args != null && args.length >0 && args[0] != null && args[0] instanceof TrackingAreaShortVo) form.cmbArea().setValue((TrackingAreaShortVo) args[0]); if (args != null && args.length >1 && args[1] != null && args[1] instanceof TrackingStatus) form.cmbStatus().setValue((TrackingStatus) args[1]); doSearch(); }
private void initialize(Object[] args) { if (args != null && args.length >0 && args[0] != null && args[0] instanceof TrackingAreaShortVo) { form.getLocalContext().setSelectedArea((TrackingAreaShortVo) args[0]); } populateAreasCombo(); form.getLocalContext().setWhiteBoardConfigVo(null); form.getGlobalContext().Core.setPatientShort(null); }
public TrackingAreaShortVo getTrackingArea(TrackingAreaRefVo trackingAreaRef) { if(trackingAreaRef == null || trackingAreaRef.getID_TrackingArea() == null) throw new CodingRuntimeException("Cannot get TrackingArea record on null TrackingArea Id."); DomainFactory factory = getDomainFactory(); TrackingArea doTrackingArea = (TrackingArea) factory.getDomainObject(TrackingArea.class, trackingAreaRef.getID_TrackingArea()); return TrackingAreaShortVoAssembler.create(doTrackingArea); }
public TrackingForClinicianWorklistAndTriageVoCollection listTrackingPatients(TrackingAreaShortVo trackingArea, TrackingStatus trackingStatus, ILocation edLoc) { DomainFactory factory = getDomainFactory(); StringBuilder hqlJoins = new StringBuilder("select tr from Tracking as tr left join tr.patient as p left join tr.attendance as att left join tr.currentArea as ta"); StringBuilder hqlConditions = new StringBuilder(" where "); ArrayList<String> paramNames = new ArrayList<String>(); ArrayList<Object> paramValues = new ArrayList<Object>(); String and = " and "; if( trackingArea != null ) { if (trackingArea.getIsOverallViewIsNotNull() && trackingArea.getIsOverallView().equals(true)) { hqlConditions.append(" ta.id is not null "); } else { hqlConditions.append(" ta.id = :TrackingAreaId "); paramNames.add("TrackingAreaId"); paramValues.add(trackingArea.getID_TrackingArea()); } } if( edLoc != null) { hqlJoins.append(" left join tr.eDLocation as loc "); hqlConditions.append(and); hqlConditions.append(" loc.id = :locId "); paramNames.add("locId"); paramValues.add(edLoc.getID()); and = " and "; } else { if( trackingArea != null ) { hqlJoins.append(" left join tr.eDLocation as loc "); hqlConditions.append(and); hqlConditions.append(" loc.id = :locId "); paramNames.add("locId"); paramValues.add(trackingArea.getEDLocation().getID_Location()); and = " and "; } } if( trackingStatus != null) { hqlJoins.append(" left join tr.currentStatus as cs left join cs.status as s "); hqlConditions.append(and); hqlConditions.append(" s.id = :statusId "); paramNames.add("statusId"); paramValues.add(trackingStatus.getID()); and = " and "; } List<?> patients = factory.find(hqlJoins.append(hqlConditions.toString()).toString(), paramNames, paramValues); if( patients != null && patients.size() > 0 ) { return TrackingForClinicianWorklistAndTriageVoAssembler.createTrackingForClinicianWorklistAndTriageVoCollectionFromTracking(patients); } return null; }
public TrackingForPatientWhiteBoardVoCollection listTrackingPatients(ims.emergency.vo.TrackingAreaShortVo trackingArea, ims.emergency.vo.lookups.TrackingStatus trackingStatus, ims.framework.interfaces.ILocation edLoc) { DomainFactory factory = getDomainFactory(); StringBuilder hqlJoins = new StringBuilder("select tr from Tracking as tr left join tr.patient as p left join tr.attendance as att left join tr.currentArea as ta"); StringBuilder hqlConditions = new StringBuilder(); ArrayList<String> paramNames = new ArrayList<String>(); ArrayList<Object> paramValues = new ArrayList<Object>(); String and = ""; if( trackingArea != null ) { if (trackingArea.getIsOverallViewIsNotNull() && trackingArea.getIsOverallView().equals(true)) { hqlConditions.append(and); hqlConditions.append(" ta.id is not null "); and = " and "; } else { hqlConditions.append(and); hqlConditions.append(" ta.id = :TrackingAreaId "); paramNames.add("TrackingAreaId"); paramValues.add(trackingArea.getID_TrackingArea()); and = " and "; } } if( edLoc != null) { hqlJoins.append(" left join tr.eDLocation as loc "); hqlConditions.append(and); hqlConditions.append(" loc.id = :locId "); paramNames.add("locId"); paramValues.add(edLoc.getID()); and = " and "; } else { if( trackingArea != null ) { hqlJoins.append(" left join tr.eDLocation as loc "); hqlConditions.append(and); hqlConditions.append(" loc.id = :locId "); paramNames.add("locId"); paramValues.add(trackingArea.getEDLocation().getID_Location()); and = " and "; } } if( trackingStatus != null) { hqlJoins.append(" left join tr.currentStatus as cs left join cs.status as s "); hqlConditions.append(and); hqlConditions.append(" s.id = :statusId "); paramNames.add("statusId"); paramValues.add(trackingStatus.getID()); and = " and "; } if (hqlConditions.length()>0) { hqlConditions.insert(0, " where "); } List<?> patients = factory.find((hqlJoins.append( hqlConditions)).toString(), paramNames, paramValues); if( patients != null && patients.size() > 0 ) { return TrackingForPatientWhiteBoardVoAssembler.createTrackingForPatientWhiteBoardVoCollectionFromTracking(patients); } return null; }
public TrackingForClinicianWorklistAndTriageVoCollection listTrackingPatients(TrackingAreaShortVo trackingArea, TrackingStatus trackingStatus, ILocation edLoc) { DomainFactory factory = getDomainFactory(); StringBuilder hqlJoins = new StringBuilder("select tr from Tracking as tr left join tr.patient as p left join tr.attendance as att left join tr.currentArea as ta"); StringBuilder hqlConditions = new StringBuilder(); ArrayList<String> paramNames = new ArrayList<String>(); ArrayList<Object> paramValues = new ArrayList<Object>(); String and = ""; if( trackingArea != null ) { if (trackingArea.getIsOverallViewIsNotNull() && trackingArea.getIsOverallView().equals(true)) { hqlConditions.append(and); hqlConditions.append(" ta.id is not null "); and = " and "; } else { hqlConditions.append(and); hqlConditions.append(" ta.id = :TrackingAreaId "); paramNames.add("TrackingAreaId"); paramValues.add(trackingArea.getID_TrackingArea()); and = " and "; } } if( edLoc != null) { hqlJoins.append(" left join tr.eDLocation as loc "); hqlConditions.append(and); hqlConditions.append(" loc.id = :locId "); paramNames.add("locId"); paramValues.add(edLoc.getID()); and = " and "; } else { if( trackingArea != null ) { hqlJoins.append(" left join tr.eDLocation as loc "); hqlConditions.append(and); hqlConditions.append(" loc.id = :locId "); paramNames.add("locId"); paramValues.add(trackingArea.getEDLocation().getID_Location()); and = " and "; } } if( trackingStatus != null) { hqlJoins.append(" left join tr.currentStatus as cs left join cs.status as s "); hqlConditions.append(and); hqlConditions.append(" s.id = :statusId "); paramNames.add("statusId"); paramValues.add(trackingStatus.getID()); and = " and "; } if (hqlConditions.length()>0) { hqlConditions.insert(0, " where "); } List<?> patients = factory.find((hqlJoins.append( hqlConditions)).toString(), paramNames, paramValues); if( patients != null && patients.size() > 0 ) { return TrackingForClinicianWorklistAndTriageVoAssembler.createTrackingForClinicianWorklistAndTriageVoCollectionFromTracking(patients); } return null; }