private void addFinding() { clearFindingControls(); form.getLocalContext().setVoDrawingGraphicFinding(new DrawingGraphicFindingVo()); form.getLocalContext().setIsNew(new Boolean(true)); form.getLocalContext().setInactiveFindingQuestions(null); setDefaultControlData(); enableColourImgControls(); setDefaultColourImgValue(); enableFindingsTab(true); enableSearchTab(false); showTabView(); enableReturnToList(); if (isDialog() == false) setFormMode(FormMode.EDIT); }
private void editFinding(FormMode formMode) { form.getLocalContext().setIsNew(new Boolean(false)); DrawingGraphicFindingVo voDrawingGraphic = (DrawingGraphicFindingVo) getSelectedFinding(); form.getLocalContext().setVoDrawingGraphicFinding(voDrawingGraphic); clearFindingControls(); displayFinding(voDrawingGraphic); displayQuestions(voDrawingGraphic); enableFindingsTab(true); enableSearchTab(false); enableColourImgControls(); showTabView(); enableReturnToList(); if (isDialog() == false) setFormMode(formMode); }
private void setFinding() { if (isNewRecordAdded()) { //Add New Record in the grid DrawingGraphicFindingVo voDrawingGraphicFinding = form.getLocalContext().getVoDrawingGraphicFinding(); if (voDrawingGraphicFinding != null && voDrawingGraphicFinding.getID_DrawingGraphicFindingIsNotNull()) { DrawingGraphicFindingVoCollection voColl = new DrawingGraphicFindingVoCollection(); voColl.add(voDrawingGraphicFinding); displayListedFindings(voColl); form.lyrFindings().tabSearch().lyrFindingSearch().tabPageSelect().dyngrdSelect().setValue(voDrawingGraphicFinding); enableContextMenu(); } } else { search(); } }
private DynamicGridRow getDynamicRowByValue(DrawingGraphicFindingVo voDrawingGraphicFinding) { for (int i = 0; voDrawingGraphicFinding != null && i < form.lyrDetails().tabFindings().dyngrdAssessmentFindings().getRows().size(); i++) { DynamicGridRow selRow = form.lyrDetails().tabFindings().dyngrdAssessmentFindings().getRows().get(i); Object objValue = selRow.getValue(); GraphicAssessmentFindingVo voGraphicAssessmentFinding = objValue != null ? (GraphicAssessmentFindingVo) objValue : null; if (voGraphicAssessmentFinding != null) { if (voGraphicAssessmentFinding.getFindingIsNotNull() && voGraphicAssessmentFinding.getFinding().equals(voDrawingGraphicFinding)) { return selRow; } } } return null; }
private DynamicGridRow getDynamicRowByValueWithStages(DrawingGraphicFindingVo voDrawingGraphicFinding) { for (int i = 0; voDrawingGraphicFinding != null && i < form.lyrDetails().tabFindingsWithStages().dyngrdFindingWithStage().getRows().size(); i++) { DynamicGridRow selRow = form.lyrDetails().tabFindingsWithStages().dyngrdFindingWithStage().getRows().get(i); Object objValue = selRow.getValue(); GraphicAssessmentFindingVo voGraphicAssessmentFinding = objValue != null ? (GraphicAssessmentFindingVo) objValue : null; if (voGraphicAssessmentFinding != null) { if (voGraphicAssessmentFinding.getFindingIsNotNull() && voGraphicAssessmentFinding.getFinding().equals(voDrawingGraphicFinding)) { return selRow; } } } return null; }
private DrawingGraphicFindingVo getGraphicFinding(int brushId) { PatientAssessmentVo patientAssessmentVo = form.getLocalContext().getPatientAssessment(); if(patientAssessmentVo == null || patientAssessmentVo.getAssessmentData() == null) return null; PatientAssessmentDataVo voPatAssessmentData = patientAssessmentVo.getAssessmentData(); GraphicAssessmentFindingVoCollection findingColl = voPatAssessmentData.getGraphic().getFindingsAndQuestions(); if (findingColl != null) { for (int i = 0; i < findingColl.size(); i++) { if (findingColl.get(i).getFindingIsNotNull() && findingColl.get(i).getFinding().getID_DrawingGraphicFindingIsNotNull() && findingColl.get(i).getFinding().getID_DrawingGraphicFinding().intValue() == brushId) { return findingColl.get(i).getFinding(); } } } return null; }
private FindingStageQuestionsVo getFindingStageQuestions(GraphicAssessmentVo graphic, DrawingGraphicFindingVo graphicFinding, GraphicAssessmentStageVo stage) { if(graphic.getFindingsAndQuestionsIsNotNull()) { for (int i = 0; i < graphic.getFindingsAndQuestions().size(); i++) { GraphicAssessmentFindingVo gafVo = graphic.getFindingsAndQuestions().get(i); if(gafVo.getFindingIsNotNull() && gafVo.getFinding().equals(graphicFinding) && gafVo.getFindingStageIsNotNull()) { for (int j = 0; j < gafVo.getFindingStage().size(); j++) { FindingStageQuestionsVo fsqVo = gafVo.getFindingStage().get(j); if(fsqVo.getAssessmentStageIsNotNull() && fsqVo.getAssessmentStage().equals(stage)) return fsqVo; } } } } return null; }
private DrawingGraphicFindingVo get_GraphicFinding(int brushId) { DrawingGraphicImageVo voDrawingGraphicImage = form.getLocalContext().getCurrentImage(); Graphic_AssessmentFindingVoCollection findingColl = get_FindingCollection(voDrawingGraphicImage); Graphic_AssessmentFindingVo voGraphicAssessmentFinding = new Graphic_AssessmentFindingVo(); if (findingColl != null) { for (int i = 0; i < findingColl.size(); i++) { if (findingColl.get(i).getFindingIsNotNull() && findingColl.get(i).getFinding().getID_DrawingGraphicFindingIsNotNull() && findingColl.get(i).getFinding().getID_DrawingGraphicFinding().intValue() == brushId) { voGraphicAssessmentFinding = findingColl.get(i); return voGraphicAssessmentFinding.getFinding(); } } } return null; }
private DrawingGraphicFindingVo getGraphicFinding(int brushId) { DrawingGraphicImageVo voDrawingGraphicImage = form.getLocalContext().getCurrentImage(); GraphicAssessmentFindingVoCollection findingColl = getFindingCollection(voDrawingGraphicImage); GraphicAssessmentFindingVo voGraphicAssessmentFinding = new GraphicAssessmentFindingVo(); if (findingColl != null) { for (int i = 0; i < findingColl.size(); i++) { if (findingColl.get(i).getFindingIsNotNull() && findingColl.get(i).getFinding().getID_DrawingGraphicFindingIsNotNull() && findingColl.get(i).getFinding().getID_DrawingGraphicFinding().intValue() == brushId) { voGraphicAssessmentFinding = findingColl.get(i); return voGraphicAssessmentFinding.getFinding(); } } } return null; }
private DrawingGraphicFindingVo getGraphicFinding(int brushId) { DrawingGraphicImageVo voDrawingGraphicImage = form.cmbImages().getValue(); GraphicAssessmentFindingVoCollection findingColl = getFindingCollection(voDrawingGraphicImage); GraphicAssessmentFindingVo voGraphicAssessmentFinding = new GraphicAssessmentFindingVo(); if (findingColl != null) { for (int i = 0; i < findingColl.size(); i++) { if (findingColl.get(i).getFindingIsNotNull() && findingColl.get(i).getFinding().getID_DrawingGraphicFindingIsNotNull() && findingColl.get(i).getFinding().getID_DrawingGraphicFinding().intValue() == brushId) { voGraphicAssessmentFinding = findingColl.get(i); return voGraphicAssessmentFinding.getFinding(); } } } return null; }