private void openOpNote() { SurgicalOperationNotesListVo value = form.grdSurgicalOPs().getValue(); form.getGlobalContext().Core.setCurrentCareContext(domain.getCareContext(value.getCareContext())); engine.open(form.getForms().Clinical.SurgicalOpNotes); }
public int compare(Object ob1, Object ob2) { String rez1 = null; String rez2 = null; if(ob1 instanceof SurgicalOperationNotesListVo ) { SurgicalOperationNotesListVo ps1 = (SurgicalOperationNotesListVo)ob1; rez1 = (ps1.getCareContext() != null && ps1.getCareContext().getEpisodeOfCare() != null && ps1.getCareContext().getEpisodeOfCare().getCareSpell() != null && ps1.getCareContext().getEpisodeOfCare().getCareSpell().getPatient() != null) ? ps1.getCareContext().getEpisodeOfCare().getCareSpell().getPatient().getISelectedPatientName():null; } if(ob2 instanceof SurgicalOperationNotesListVo) { SurgicalOperationNotesListVo ps2 = (SurgicalOperationNotesListVo)ob2; rez2 = (ps2.getCareContext() != null && ps2.getCareContext().getEpisodeOfCare() != null && ps2.getCareContext().getEpisodeOfCare().getCareSpell() != null && ps2.getCareContext().getEpisodeOfCare().getCareSpell().getPatient() != null) ? ps2.getCareContext().getEpisodeOfCare().getCareSpell().getPatient().getISelectedPatientName():null; } if(rez1 != null && rez2 != null) return rez1.compareToIgnoreCase(rez2)*direction; if(rez1 != null && rez2 == null) return direction; if(rez2 != null && rez1 == null) return (-1)*direction; return 0; }
public int compare(Object ob1, Object ob2) { String rez1 = null; String rez2 = null; if(ob1 instanceof SurgicalOperationNotesListVo ) { SurgicalOperationNotesListVo ps1 = (SurgicalOperationNotesListVo)ob1; rez1 = (ps1.getCareContext() != null && ps1.getCareContext().getEpisodeOfCare() != null && ps1.getCareContext().getEpisodeOfCare().getResponsibleHCP() != null) ? ps1.getCareContext().getEpisodeOfCare().getResponsibleHCP().getIMosName():null; } if(ob2 instanceof SurgicalOperationNotesListVo) { SurgicalOperationNotesListVo ps2 = (SurgicalOperationNotesListVo)ob2; rez2 = (ps2.getCareContext() != null && ps2.getCareContext().getEpisodeOfCare() != null && ps2.getCareContext().getEpisodeOfCare().getResponsibleHCP() != null) ? ps2.getCareContext().getEpisodeOfCare().getResponsibleHCP().getIMosName():null; } if(rez1 != null && rez2 != null) return rez1.compareToIgnoreCase(rez2)*direction; if(rez1 != null && rez2 == null) return direction; if(rez2 != null && rez1 == null) return (-1)*direction; return 0; }
public int compare(Object ob1, Object ob2) { String rez1 = null; String rez2 = null; if(ob1 instanceof SurgicalOperationNotesListVo ) { SurgicalOperationNotesListVo ps1 = (SurgicalOperationNotesListVo)ob1; rez1 = (ps1.getProceduresPerformed() != null && ps1.getProceduresPerformed().size() > 0 && ps1.getProceduresPerformed().get(0) instanceof PatientProcedureSurgicalOpVo && ps1.getProceduresPerformed().get(0).getPeformedBy() != null) ? ps1.getProceduresPerformed().get(0).getPeformedBy().getIMosName(): null; } if(ob2 instanceof SurgicalOperationNotesListVo) { SurgicalOperationNotesListVo ps2 = (SurgicalOperationNotesListVo)ob2; rez2 = (ps2.getProceduresPerformed() != null && ps2.getProceduresPerformed().size() > 0 && ps2.getProceduresPerformed().get(0) instanceof PatientProcedureSurgicalOpVo && ps2.getProceduresPerformed().get(0).getPeformedBy() != null) ? ps2.getProceduresPerformed().get(0).getPeformedBy().getIMosName(): null; } if(rez1 != null && rez2 != null) return rez1.compareToIgnoreCase(rez2)*direction; if(rez1 != null && rez2 == null) return direction; if(rez2 != null && rez1 == null) return (-1)*direction; return 0; }
public int compare(Object ob1, Object ob2) { String rez1 = null; String rez2 = null; if(ob1 instanceof SurgicalOperationNotesListVo ) { SurgicalOperationNotesListVo ps1 = (SurgicalOperationNotesListVo)ob1; rez1 = (ps1.getMainProcedure() != null && ps1.getMainProcedure().getProcedure() != null) ? ps1.getMainProcedure().getProcedure().getProcedureName(): null; } if(ob2 instanceof SurgicalOperationNotesListVo) { SurgicalOperationNotesListVo ps2 = (SurgicalOperationNotesListVo)ob2; rez2 = (ps2.getMainProcedure() != null && ps2.getMainProcedure().getProcedure() != null) ? ps2.getMainProcedure().getProcedure().getProcedureName(): null; } if(rez1 != null && rez2 != null) return rez1.compareToIgnoreCase(rez2)*direction; if(rez1 != null && rez2 == null) return direction; if(rez2 != null && rez1 == null) return (-1)*direction; return 0; }
public int compare(Object ob1, Object ob2) { Date rez1 = null; Date rez2 = null; if(ob1 instanceof SurgicalOperationNotesListVo ) { SurgicalOperationNotesListVo ps1 = (SurgicalOperationNotesListVo)ob1; rez1 = ps1.getSignOffDateTime() != null ? ps1.getSignOffDateTime().getDate(): null; } if(ob2 instanceof SurgicalOperationNotesListVo) { SurgicalOperationNotesListVo ps2 = (SurgicalOperationNotesListVo)ob2; rez2 = ps2.getSignOffDateTime() != null ? ps2.getSignOffDateTime().getDate(): null; } if(rez1 != null && rez2 != null) return rez1.compareTo(rez2)*direction; if(rez1 != null && rez2 == null) return direction; if(rez2 != null && rez1 == null) return (-1)*direction; return 0; }
public int compare(Object ob1, Object ob2) { String rez1 = null; String rez2 = null; if(ob1 instanceof SurgicalOperationNotesListVo ) { SurgicalOperationNotesListVo ps1 = (SurgicalOperationNotesListVo)ob1; rez1 = ps1.getSignOffHCP() != null ? ps1.getSignOffHCP().getIMosName(): null; } if(ob2 instanceof SurgicalOperationNotesListVo) { SurgicalOperationNotesListVo ps2 = (SurgicalOperationNotesListVo)ob2; rez2 = ps2.getSignOffHCP() != null ? ps2.getSignOffHCP().getIMosName(): null; } if(rez1 != null && rez2 != null) return rez1.compareToIgnoreCase(rez2)*direction; if(rez1 != null && rez2 == null) return direction; if(rez2 != null && rez1 == null) return (-1)*direction; return 0; }
private void addRowToGrid(SurgicalOperationNotesListVo record) { if (record == null) return; grdSurgicalOPsRow newRow = form.grdSurgicalOPs().getRows().newRow(); boolean episodeOfCareNotNull = record.getCareContextIsNotNull() && record.getCareContext().getEpisodeOfCareIsNotNull(); newRow.setColumnPatient(episodeOfCareNotNull && record.getCareContext().getEpisodeOfCare().getCareSpellIsNotNull() && record.getCareContext().getEpisodeOfCare().getCareSpell().getPatientIsNotNull() ? record.getCareContext().getEpisodeOfCare().getCareSpell().getPatient().getISelectedPatientName(): null); //----------------------------- if(episodeOfCareNotNull && record.getCareContext().getEpisodeOfCare().getCareSpellIsNotNull() && record.getCareContext().getEpisodeOfCare().getCareSpell().getPatientIsNotNull() ) { String strTemp = new String(); for(PatientId temp:record.getCareContext().getEpisodeOfCare().getCareSpell().getPatient().getIdentifiers()) { strTemp = strTemp +temp.getType().toString() + '=' + temp.getValue(); strTemp += ','; } if(strTemp.length() > 0) { int n = strTemp.lastIndexOf(','); strTemp = strTemp.substring(0, n); //take out the last , } newRow.setTooltipForColumnPatient(strTemp); } //------------------------------ newRow.setColumnConsultant(episodeOfCareNotNull && record.getCareContext().getEpisodeOfCare().getResponsibleHCPIsNotNull() ? record.getCareContext().getEpisodeOfCare().getResponsibleHCP().getIMosName(): null); newRow.setColumnOpSurgeon(record.getProceduresPerformedIsNotNull() && record.getProceduresPerformed().size()>0 && (record.getProceduresPerformed().get(0) instanceof PatientProcedureSurgicalOpVo) && record.getProceduresPerformed().get(0).getPeformedByIsNotNull()? record.getProceduresPerformed().get(0).getPeformedBy().getIMosName() : null); newRow.setColumnPrimProcedure(record.getMainProcedureIsNotNull() && record.getMainProcedure().getProcedureIsNotNull() ? record.getMainProcedure().getProcedure().getProcedureName(): null); newRow.setColumnSignoffDate(record.getSignOffDateTimeIsNotNull()? record.getSignOffDateTime().getDate():null); newRow.setColumnSignoffHcp(record.getSignOffHCPIsNotNull() ? record.getSignOffHCP().getIMosName() : null); newRow.setValue(record); }
@Override protected void onGrdSurgicalOPsGridHeaderClicked(int column) throws PresentationLogicException { SurgicalOperationNotesListVo temp = form.grdSurgicalOPs().getValue(); sortColumn(column); form.grdSurgicalOPs().setValue(temp); }