Java 类ims.core.vo.DrawingGraphicImageVo 实例源码

项目:AvoinApotti    文件:Logic.java   
private String getImageRowTolltip(DrawingGraphicImageVo voDrawingGraphicImage)
{
    if (voDrawingGraphicImage != null)
    {
        StringBuffer tooltip = new StringBuffer();
        if (voDrawingGraphicImage.getImageDescriptionIsNotNull())
        {
            tooltip.append("*Image Description: *");
            tooltip.append(voDrawingGraphicImage.getImageDescription());
            tooltip.append(CR);
        }
        if (voDrawingGraphicImage.getVersionNumberIsNotNull())
        {
            tooltip.append("*Version No. : *");
            tooltip.append(voDrawingGraphicImage.getVersionNumber());
            tooltip.append(CR);
        }

        return new Textile().process(tooltip.toString());
    }

    return "";
}
项目:AvoinApotti    文件:Logic.java   
private void processEditedFinding(PatientAssessmentVo assessment, PatientGraphicAssessmentFindingVo voPatientGraphicAssessmentFinding)
{
    PatientAssessmentDataVo voPatAssessmentData = assessment.getAssessmentData();

    DrawingGraphicImageVo voDrawingGraphicImage = form.getLocalContext().getCurrentImage();
    if (voPatAssessmentData != null && voPatAssessmentData.getGraphicFindingsIsNotNull())
    {
        for (int i = 0; i < voPatAssessmentData.getGraphicFindings().size(); i++)
        {
            // Check to be in the context of the same Patient Graphic Assessment
            PatientGraphicAssessmentVo voPatientGraphicAssessment = voPatAssessmentData.getGraphicFindings().get(i);
            if (voPatientGraphicAssessment.getGraphicImageIsNotNull() && voPatientGraphicAssessment.getGraphicImage().equals(voDrawingGraphicImage))
            {
                int index = voPatientGraphicAssessment.getPatientGraphicFinding().indexOf(voPatientGraphicAssessmentFinding);
                if (index >= 0)
                    voPatAssessmentData.getGraphicFindings().get(i).getPatientGraphicFinding().set(index, voPatientGraphicAssessmentFinding);
                else
                    voPatAssessmentData.getGraphicFindings().get(i).getPatientGraphicFinding().add(voPatientGraphicAssessmentFinding);

                assessment.setAssessmentData(voPatAssessmentData);
                form.getLocalContext().setPatientAssessment(assessment);
                break;
            }
        }
    }
}
项目:AvoinApotti    文件:Logic.java   
private void process_EditedFinding(Patient_AssessmentVo assessment, Patient_GraphicAssessmentFindingVo voPatientGraphicAssessmentFinding)
{
    Patient_AssessmentDataVo voPatAssessmentData = assessment.getAssessmentData();

    DrawingGraphicImageVo voDrawingGraphicImage = form.getLocalContext().getCurrentImage();
    if (voPatAssessmentData != null && voPatAssessmentData.getGraphicFindingsIsNotNull())
    {
        for (int i = 0; i < voPatAssessmentData.getGraphicFindings().size(); i++)
        {
            // Check to be in the context of the same Patient Graphic Assessment
            Patient_GraphicAssessmentVo voPatientGraphicAssessment = voPatAssessmentData.getGraphicFindings().get(i);
            if (voPatientGraphicAssessment.getGraphicImageIsNotNull() && voPatientGraphicAssessment.getGraphicImage().equals(voDrawingGraphicImage))
            {
                int index = voPatientGraphicAssessment.getPatientGraphicFinding().indexOf(voPatientGraphicAssessmentFinding);
                if (index >= 0)
                    voPatAssessmentData.getGraphicFindings().get(i).getPatientGraphicFinding().set(index, voPatientGraphicAssessmentFinding);
                else
                    voPatAssessmentData.getGraphicFindings().get(i).getPatientGraphicFinding().add(voPatientGraphicAssessmentFinding);

                assessment.setAssessmentData(voPatAssessmentData);
                form.getLocalContext().setPatient_Assessment(assessment);
                break;
            }
        }
    }
}
项目:AvoinApotti    文件:Logic.java   
private void configureImageSelection(GraphicAssessmentVo config)
{
    configureTabs();

    for (int x = 0; x < config.getImages().size(); x++)
    {
        GenForm.lyrAssessmentLayer.tabSelectImageContainer.grdImagesRow row = form.lyrAssessment().tabSelectImage().grdImages().getRows().newRow();
        DrawingGraphicImageVo img = config.getImages().get(x);
        if (img != null)
        {
            String imageName = img.getImageName();
            row.setValue(img);
            row.setcolImage(imageName == null ? "?" : imageName);
        }
    }
}
项目:AvoinApotti    文件:Logic.java   
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;
}
项目:AvoinApotti    文件:Logic.java   
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;
}
项目:AvoinApotti    文件:Logic.java   
private void configureImageSelection(Graphic_AssessmentVo config)
{
    configure_Tabs();

    for (int x = 0; x < config.getImages().size(); x++)
    {
        GenForm.lyrAssessmentLayer.tabSelectImageContainer.grdImagesRow row = form.lyrAssessment().tabSelectImage().grdImages().getRows().newRow();
        DrawingGraphicImageVo img = config.getImages().get(x);
        if (img != null)
        {
            String imageName = img.getImageName();
            row.setValue(img);
            row.setcolImage(imageName == null ? "?" : imageName);
        }
    }
}
项目:AvoinApotti    文件:Logic.java   
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;
}
项目:AvoinApotti    文件:Logic.java   
private GraphicAssessmentFindingVoCollection getFindingCollection(DrawingGraphicImageVo voDrawingGraphicImage)
{
    UserDefinedObjectComponentVo voUserDefComp = getEditedComponent();
    if (voUserDefComp != null && voUserDefComp.getGraphicIsNotNull() && voUserDefComp.getGraphic().getImagesIsNotNull())
    {
        for (int i = 0; i < voUserDefComp.getGraphic().getImages().size(); i++)
        {
            if (voUserDefComp.getGraphic().getImages().get(i).equals(voDrawingGraphicImage))
            {
                return voUserDefComp.getGraphic().getFindingsAndQuestions();
            }
        }
    }

    return null;
}
项目:AvoinApotti    文件:Logic.java   
private void populateCombos()
{
    //Image Combo
    UserDefinedObjectComponentVo voUserDefComp = getEditedComponent();
    if (voUserDefComp != null && voUserDefComp.getGraphicIsNotNull() && voUserDefComp.getGraphic().getImagesIsNotNull())
    {
        voUserDefComp.getGraphic().getImages().sort();
        for (int i = 0; i < voUserDefComp.getGraphic().getImages().size(); i++)
        {
            DrawingGraphicImageVo voImage = voUserDefComp.getGraphic().getImages().get(i);
            form.cmbImages().newRow(voImage, voImage.getImageName());
            if (i == 0)
                form.cmbImages().setValue(voImage);
        }
    }

    loadStatusCombo(false);
}
项目:AvoinApotti    文件:Logic.java   
private void setImageName(DrawingGraphicImageVo voDrawingGraphicImage) {
    if (voDrawingGraphicImage.getID_DrawingGraphicImage() == null)
    {
        String imageName = form.lyrDrawing().tabImageSelect().txtImageName().getValue();
        if (imageName == null || imageName.equals(""))
        {
            engine.showMessage("Please enter an Image Name");
            form.lyrDrawing().tabImageSelect().txtImageName().setFocus();
            form.lyrDrawing().tabImageSelect().setEnabled(true);
            form.lyrDrawing().showtabImageSelect();
            return;
        }

        DrawingControlGroup group = form.lyrDrawing().tabRegionConfig().drawingConfig().getAreas();
        group.setName(imageName);
        form.lyrDrawing().tabRegionConfig().drawingConfig().setAreas(group);
    }
}
项目:AvoinApotti    文件:Logic.java   
private String getTooltip(DrawingGraphicImageVo voDGImage)
{
    if (voDGImage != null)
    {
        StringBuffer tooltip = new StringBuffer();
        if (voDGImage.getImageIsNotNull() && voDGImage.getImage().getImagePathIsNotNull())
        {
            tooltip.append("*Image Path: *");
            tooltip.append(voDGImage.getImage().getImagePath());
            tooltip.append(CR);
        }
        if (voDGImage.getImageDescriptionIsNotNull())
        {
            tooltip.append("*Description: *");
            tooltip.append(voDGImage.getImageDescription());
            tooltip.append(CR);
        }

        return new Textile().process(tooltip.toString());
    }

    return "";
}
项目:AvoinApotti    文件:Logic.java   
protected void populateScreenFromData(DrawingGraphicImageVo voGraphicImage)
{
    form.getLocalContext().setImageRecord(voGraphicImage);
    this.clearScreen();
    super.populateScreenFromData(voGraphicImage);
    // Populate the unbinded controls
    if (voGraphicImage != null && voGraphicImage.getImageIsNotNull() && voGraphicImage.getImage().getID_AppImageIsNotNull())
    {
        Image repImage = engine.getRegisteredImage(voGraphicImage.getImage().getID_AppImage().intValue());
        if(repImage != null)
        {
            form.lyrDrawing().tabImageSelect().imgPreview().setValue(repImage);
            form.lyrDrawing().tabImageSelect().txtImagePath().setValue(repImage.getImagePath());
        }
    }
    // Populate the drawing Image
    setDefaultImage(voGraphicImage);

    if (form.getMode().equals(FormMode.VIEW))
    {
        form.btnUpdate().setVisible(true);
    }
    enbleRegionConfigTab(true);
}
项目:AvoinApotti    文件:Logic.java   
private void copyDrawingDetails()
{
    if (form.getGlobalContext().Admin.getDrawingGraphicImageShortVo() != null && form.getGlobalContext().Admin.getDrawingGraphicImageShortVo().getID_DrawingGraphicImageIsNotNull())
    {
        form.getLocalContext().setIsCopyDrawingMode(new Boolean(true));
        DrawingGraphicImageVo voDrawing = domain.getDrawingGraphicImage(form.getGlobalContext().Admin.getDrawingGraphicImageShortVo());
        if (voDrawing == null)
        {
            engine.showMessage("Please select a record");
            return;
        }

        voDrawing = setCopiedDrawingVo(voDrawing);
        populateScreenFromData(voDrawing);
        form.setMode(FormMode.EDIT);
    }
}
项目:AvoinApotti    文件:Logic.java   
private void loadAvalilableImages()
{
    form.lyrTabs().tabDrawing().cmbGraphicAdnotationImage().clear();

    GraphicAssessmentVo graphicAssessment = domain.getActiveGraphicAssessment(UserDefinedAssessmentType.MEDICALNOTING);
    if (graphicAssessment == null)
        return;

    for (int i = 0; i < graphicAssessment.getImages().size(); i++)
    {
        DrawingGraphicImageVo image = graphicAssessment.getImages().get(i);
        if (image != null)
        {
            form.lyrTabs().tabDrawing().cmbGraphicAdnotationImage().newRow(image, image.getImageName() == null ? "Untitled" : image.getImageName());
        }
    }
}
项目:openmaxims-linux    文件:Logic.java   
private void setImageName(DrawingGraphicImageVo voDrawingGraphicImage) {
    if (voDrawingGraphicImage.getID_DrawingGraphicImage() == null)
    {
        String imageName = form.lyrDrawing().tabImageSelect().txtImageName().getValue();
        if (imageName == null || imageName.equals(""))
        {
            engine.showMessage("Please enter an Image Name");
            form.lyrDrawing().tabImageSelect().txtImageName().setFocus();
            form.lyrDrawing().tabImageSelect().setEnabled(true);
            form.lyrDrawing().showtabImageSelect();
            return;
        }

        DrawingControlGroup group = form.lyrDrawing().tabRegionConfig().drawingConfig().getAreas();
        group.setName(imageName);
        form.lyrDrawing().tabRegionConfig().drawingConfig().setAreas(group);
    }
}
项目:openMAXIMS    文件:Logic.java   
private void processEditedFinding(PatientAssessmentVo assessment, PatientGraphicAssessmentFindingVo voPatientGraphicAssessmentFinding)
{
    PatientAssessmentDataVo voPatAssessmentData = assessment.getAssessmentData();

    DrawingGraphicImageVo voDrawingGraphicImage = form.getLocalContext().getCurrentImage();
    if (voPatAssessmentData != null && voPatAssessmentData.getGraphicFindingsIsNotNull())
    {
        for (int i = 0; i < voPatAssessmentData.getGraphicFindings().size(); i++)
        {
            // Check to be in the context of the same Patient Graphic Assessment
            PatientGraphicAssessmentVo voPatientGraphicAssessment = voPatAssessmentData.getGraphicFindings().get(i);
            if (voPatientGraphicAssessment.getGraphicImageIsNotNull() && voPatientGraphicAssessment.getGraphicImage().equals(voDrawingGraphicImage))
            {
                int index = voPatientGraphicAssessment.getPatientGraphicFinding().indexOf(voPatientGraphicAssessmentFinding);
                if (index >= 0)
                    voPatAssessmentData.getGraphicFindings().get(i).getPatientGraphicFinding().set(index, voPatientGraphicAssessmentFinding);
                else
                    voPatAssessmentData.getGraphicFindings().get(i).getPatientGraphicFinding().add(voPatientGraphicAssessmentFinding);

                assessment.setAssessmentData(voPatAssessmentData);
                form.getLocalContext().setPatientAssessment(assessment);
                break;
            }
        }
    }
}
项目:openMAXIMS    文件:Logic.java   
private void process_EditedFinding(Patient_AssessmentVo assessment, Patient_GraphicAssessmentFindingVo voPatientGraphicAssessmentFinding)
{
    Patient_AssessmentDataVo voPatAssessmentData = assessment.getAssessmentData();

    DrawingGraphicImageVo voDrawingGraphicImage = form.getLocalContext().getCurrentImage();
    if (voPatAssessmentData != null && voPatAssessmentData.getGraphicFindingsIsNotNull())
    {
        for (int i = 0; i < voPatAssessmentData.getGraphicFindings().size(); i++)
        {
            // Check to be in the context of the same Patient Graphic Assessment
            Patient_GraphicAssessmentVo voPatientGraphicAssessment = voPatAssessmentData.getGraphicFindings().get(i);
            if (voPatientGraphicAssessment.getGraphicImageIsNotNull() && voPatientGraphicAssessment.getGraphicImage().equals(voDrawingGraphicImage))
            {
                int index = voPatientGraphicAssessment.getPatientGraphicFinding().indexOf(voPatientGraphicAssessmentFinding);
                if (index >= 0)
                    voPatAssessmentData.getGraphicFindings().get(i).getPatientGraphicFinding().set(index, voPatientGraphicAssessmentFinding);
                else
                    voPatAssessmentData.getGraphicFindings().get(i).getPatientGraphicFinding().add(voPatientGraphicAssessmentFinding);

                assessment.setAssessmentData(voPatAssessmentData);
                form.getLocalContext().setPatient_Assessment(assessment);
                break;
            }
        }
    }
}
项目:openmaxims-linux    文件:Logic.java   
private String getTooltip(DrawingGraphicImageVo voDGImage)
{
    if (voDGImage != null)
    {
        StringBuffer tooltip = new StringBuffer();
        if (voDGImage.getImageIsNotNull() && voDGImage.getImage().getImagePathIsNotNull())
        {
            tooltip.append("*Image Path: *");
            tooltip.append(voDGImage.getImage().getImagePath());
            tooltip.append(CR);
        }
        if (voDGImage.getImageDescriptionIsNotNull())
        {
            tooltip.append("*Description: *");
            tooltip.append(voDGImage.getImageDescription());
            tooltip.append(CR);
        }

        return new Textile().process(tooltip.toString());
    }

    return "";
}
项目:openMAXIMS    文件:Logic.java   
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;
}
项目:openmaxims-linux    文件:Logic.java   
private void processEditedFinding(PatientAssessmentVo assessment, PatientGraphicAssessmentFindingVo voPatientGraphicAssessmentFinding)
{
    PatientAssessmentDataVo voPatAssessmentData = assessment.getAssessmentData();

    DrawingGraphicImageVo voDrawingGraphicImage = form.getLocalContext().getCurrentImage();
    if (voPatAssessmentData != null && voPatAssessmentData.getGraphicFindingsIsNotNull())
    {
        for (int i = 0; i < voPatAssessmentData.getGraphicFindings().size(); i++)
        {
            // Check to be in the context of the same Patient Graphic Assessment
            PatientGraphicAssessmentVo voPatientGraphicAssessment = voPatAssessmentData.getGraphicFindings().get(i);
            if (voPatientGraphicAssessment.getGraphicImageIsNotNull() && voPatientGraphicAssessment.getGraphicImage().equals(voDrawingGraphicImage))
            {
                int index = voPatientGraphicAssessment.getPatientGraphicFinding().indexOf(voPatientGraphicAssessmentFinding);
                if (index >= 0)
                    voPatAssessmentData.getGraphicFindings().get(i).getPatientGraphicFinding().set(index, voPatientGraphicAssessmentFinding);
                else
                    voPatAssessmentData.getGraphicFindings().get(i).getPatientGraphicFinding().add(voPatientGraphicAssessmentFinding);

                assessment.setAssessmentData(voPatAssessmentData);
                form.getLocalContext().setPatientAssessment(assessment);
                break;
            }
        }
    }
}
项目:openmaxims-linux    文件:Logic.java   
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;
}
项目:openMAXIMS    文件:Logic.java   
private void configureImageSelection(Graphic_AssessmentVo config)
{
    configure_Tabs();

    for (int x = 0; x < config.getImages().size(); x++)
    {
        GenForm.lyrAssessmentLayer.tabSelectImageContainer.grdImagesRow row = form.lyrAssessment().tabSelectImage().grdImages().getRows().newRow();
        DrawingGraphicImageVo img = config.getImages().get(x);
        if (img != null)
        {
            String imageName = img.getImageName();
            row.setValue(img);
            row.setcolImage(imageName == null ? "?" : imageName);
        }
    }
}
项目:openMAXIMS    文件:Logic.java   
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;
}
项目:openmaxims-linux    文件:Logic.java   
private void process_EditedFinding(Patient_AssessmentVo assessment, Patient_GraphicAssessmentFindingVo voPatientGraphicAssessmentFinding)
{
    Patient_AssessmentDataVo voPatAssessmentData = assessment.getAssessmentData();

    DrawingGraphicImageVo voDrawingGraphicImage = form.getLocalContext().getCurrentImage();
    if (voPatAssessmentData != null && voPatAssessmentData.getGraphicFindingsIsNotNull())
    {
        for (int i = 0; i < voPatAssessmentData.getGraphicFindings().size(); i++)
        {
            // Check to be in the context of the same Patient Graphic Assessment
            Patient_GraphicAssessmentVo voPatientGraphicAssessment = voPatAssessmentData.getGraphicFindings().get(i);
            if (voPatientGraphicAssessment.getGraphicImageIsNotNull() && voPatientGraphicAssessment.getGraphicImage().equals(voDrawingGraphicImage))
            {
                int index = voPatientGraphicAssessment.getPatientGraphicFinding().indexOf(voPatientGraphicAssessmentFinding);
                if (index >= 0)
                    voPatAssessmentData.getGraphicFindings().get(i).getPatientGraphicFinding().set(index, voPatientGraphicAssessmentFinding);
                else
                    voPatAssessmentData.getGraphicFindings().get(i).getPatientGraphicFinding().add(voPatientGraphicAssessmentFinding);

                assessment.setAssessmentData(voPatAssessmentData);
                form.getLocalContext().setPatient_Assessment(assessment);
                break;
            }
        }
    }
}
项目:openMAXIMS    文件:Logic.java   
private GraphicAssessmentFindingVoCollection getFindingCollection(DrawingGraphicImageVo voDrawingGraphicImage)
{
    UserDefinedObjectComponentVo voUserDefComp = getEditedComponent();
    if (voUserDefComp != null && voUserDefComp.getGraphicIsNotNull() && voUserDefComp.getGraphic().getImagesIsNotNull())
    {
        for (int i = 0; i < voUserDefComp.getGraphic().getImages().size(); i++)
        {
            if (voUserDefComp.getGraphic().getImages().get(i).equals(voDrawingGraphicImage))
            {
                return voUserDefComp.getGraphic().getFindingsAndQuestions();
            }
        }
    }

    return null;
}
项目:openMAXIMS    文件:Logic.java   
private void populateCombos()
{
    //Image Combo
    UserDefinedObjectComponentVo voUserDefComp = getEditedComponent();
    if (voUserDefComp != null && voUserDefComp.getGraphicIsNotNull() && voUserDefComp.getGraphic().getImagesIsNotNull())
    {
        voUserDefComp.getGraphic().getImages().sort();
        for (int i = 0; i < voUserDefComp.getGraphic().getImages().size(); i++)
        {
            DrawingGraphicImageVo voImage = voUserDefComp.getGraphic().getImages().get(i);
            form.cmbImages().newRow(voImage, voImage.getImageName());
            if (i == 0)
                form.cmbImages().setValue(voImage);
        }
    }

    loadStatusCombo(false);
}
项目:openmaxims-linux    文件:Logic.java   
private GraphicAssessmentFindingVoCollection getFindingCollection(DrawingGraphicImageVo voDrawingGraphicImage)
{
    UserDefinedObjectComponentVo voUserDefComp = getEditedComponent();
    if (voUserDefComp != null && voUserDefComp.getGraphicIsNotNull() && voUserDefComp.getGraphic().getImagesIsNotNull())
    {
        for (int i = 0; i < voUserDefComp.getGraphic().getImages().size(); i++)
        {
            if (voUserDefComp.getGraphic().getImages().get(i).equals(voDrawingGraphicImage))
            {
                return voUserDefComp.getGraphic().getFindingsAndQuestions();
            }
        }
    }

    return null;
}
项目:openMAXIMS    文件:Logic.java   
private void setImageName(DrawingGraphicImageVo voDrawingGraphicImage) {
    if (voDrawingGraphicImage.getID_DrawingGraphicImage() == null)
    {
        String imageName = form.lyrDrawing().tabImageSelect().txtImageName().getValue();
        if (imageName == null || imageName.equals(""))
        {
            engine.showMessage("Please enter an Image Name");
            form.lyrDrawing().tabImageSelect().txtImageName().setFocus();
            form.lyrDrawing().tabImageSelect().setEnabled(true);
            form.lyrDrawing().showtabImageSelect();
            return;
        }

        DrawingControlGroup group = form.lyrDrawing().tabRegionConfig().drawingConfig().getAreas();
        group.setName(imageName);
        form.lyrDrawing().tabRegionConfig().drawingConfig().setAreas(group);
    }
}
项目:openMAXIMS    文件:Logic.java   
private String getTooltip(DrawingGraphicImageVo voDGImage)
{
    if (voDGImage != null)
    {
        StringBuffer tooltip = new StringBuffer();
        if (voDGImage.getImageIsNotNull() && voDGImage.getImage().getImagePathIsNotNull())
        {
            tooltip.append("*Image Path: *");
            tooltip.append(voDGImage.getImage().getImagePath());
            tooltip.append(CR);
        }
        if (voDGImage.getImageDescriptionIsNotNull())
        {
            tooltip.append("*Description: *");
            tooltip.append(voDGImage.getImageDescription());
            tooltip.append(CR);
        }

        return new Textile().process(tooltip.toString());
    }

    return "";
}
项目:openMAXIMS    文件:Logic.java   
protected void populateScreenFromData(DrawingGraphicImageVo voGraphicImage)
{
    form.getLocalContext().setImageRecord(voGraphicImage);
    this.clearScreen();
    super.populateScreenFromData(voGraphicImage);
    // Populate the unbinded controls
    if (voGraphicImage != null && voGraphicImage.getImageIsNotNull() && voGraphicImage.getImage().getID_AppImageIsNotNull())
    {
        Image repImage = engine.getRegisteredImage(voGraphicImage.getImage().getID_AppImage().intValue());
        if(repImage != null)
        {
            form.lyrDrawing().tabImageSelect().imgPreview().setValue(repImage);
            form.lyrDrawing().tabImageSelect().txtImagePath().setValue(repImage.getImagePath());
        }
    }
    // Populate the drawing Image
    setDefaultImage(voGraphicImage);

    if (form.getMode().equals(FormMode.VIEW))
    {
        form.btnUpdate().setVisible(true);
    }
    enbleRegionConfigTab(true);
}
项目:openMAXIMS    文件:Logic.java   
private void copyDrawingDetails()
{
    if (form.getGlobalContext().Admin.getDrawingGraphicImageShortVo() != null && form.getGlobalContext().Admin.getDrawingGraphicImageShortVo().getID_DrawingGraphicImageIsNotNull())
    {
        form.getLocalContext().setIsCopyDrawingMode(new Boolean(true));
        DrawingGraphicImageVo voDrawing = domain.getDrawingGraphicImage(form.getGlobalContext().Admin.getDrawingGraphicImageShortVo());
        if (voDrawing == null)
        {
            engine.showMessage("Please select a record");
            return;
        }

        voDrawing = setCopiedDrawingVo(voDrawing);
        populateScreenFromData(voDrawing);
        form.setMode(FormMode.EDIT);
    }
}
项目:openMAXIMS    文件:Logic.java   
private void loadAvalilableImages()
{
    form.lyrTabs().tabDrawing().cmbGraphicAdnotationImage().clear();

    GraphicAssessmentVo graphicAssessment = domain.getActiveGraphicAssessment(UserDefinedAssessmentType.MEDICALNOTING);
    if (graphicAssessment == null)
        return;

    for (int i = 0; i < graphicAssessment.getImages().size(); i++)
    {
        DrawingGraphicImageVo image = graphicAssessment.getImages().get(i);
        if (image != null)
        {
            form.lyrTabs().tabDrawing().cmbGraphicAdnotationImage().newRow(image, image.getImageName() == null ? "Untitled" : image.getImageName());
        }
    }
}
项目:openMAXIMS    文件:Logic.java   
private void processEditedFinding(PatientAssessmentVo assessment, PatientGraphicAssessmentFindingVo voPatientGraphicAssessmentFinding)
{
    PatientAssessmentDataVo voPatAssessmentData = assessment.getAssessmentData();

    DrawingGraphicImageVo voDrawingGraphicImage = form.getLocalContext().getCurrentImage();
    if (voPatAssessmentData != null && voPatAssessmentData.getGraphicFindingsIsNotNull())
    {
        for (int i = 0; i < voPatAssessmentData.getGraphicFindings().size(); i++)
        {
            // Check to be in the context of the same Patient Graphic Assessment
            PatientGraphicAssessmentVo voPatientGraphicAssessment = voPatAssessmentData.getGraphicFindings().get(i);
            if (voPatientGraphicAssessment.getGraphicImageIsNotNull() && voPatientGraphicAssessment.getGraphicImage().equals(voDrawingGraphicImage))
            {
                int index = voPatientGraphicAssessment.getPatientGraphicFinding().indexOf(voPatientGraphicAssessmentFinding);
                if (index >= 0)
                    voPatAssessmentData.getGraphicFindings().get(i).getPatientGraphicFinding().set(index, voPatientGraphicAssessmentFinding);
                else
                    voPatAssessmentData.getGraphicFindings().get(i).getPatientGraphicFinding().add(voPatientGraphicAssessmentFinding);

                assessment.setAssessmentData(voPatAssessmentData);
                form.getLocalContext().setPatientAssessment(assessment);
                break;
            }
        }
    }
}
项目:openmaxims-linux    文件:Logic.java   
private void configureImageSelection(Graphic_AssessmentVo config)
{
    configure_Tabs();

    for (int x = 0; x < config.getImages().size(); x++)
    {
        GenForm.lyrAssessmentLayer.tabSelectImageContainer.grdImagesRow row = form.lyrAssessment().tabSelectImage().grdImages().getRows().newRow();
        DrawingGraphicImageVo img = config.getImages().get(x);
        if (img != null)
        {
            String imageName = img.getImageName();
            row.setValue(img);
            row.setcolImage(imageName == null ? "?" : imageName);
        }
    }
}
项目:openMAXIMS    文件:Logic.java   
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;
}
项目:openmaxims-linux    文件:Logic.java   
protected void populateScreenFromData(DrawingGraphicImageVo voGraphicImage)
{
    form.getLocalContext().setImageRecord(voGraphicImage);
    this.clearScreen();
    super.populateScreenFromData(voGraphicImage);
    // Populate the unbinded controls
    if (voGraphicImage != null && voGraphicImage.getImageIsNotNull() && voGraphicImage.getImage().getID_AppImageIsNotNull())
    {
        Image repImage = engine.getRegisteredImage(voGraphicImage.getImage().getID_AppImage().intValue());
        if(repImage != null)
        {
            form.lyrDrawing().tabImageSelect().imgPreview().setValue(repImage);
            form.lyrDrawing().tabImageSelect().txtImagePath().setValue(repImage.getImagePath());
        }
    }
    // Populate the drawing Image
    setDefaultImage(voGraphicImage);

    if (form.getMode().equals(FormMode.VIEW))
    {
        form.btnUpdate().setVisible(true);
    }
    enbleRegionConfigTab(true);
}
项目:openMAXIMS    文件:Logic.java   
private void populateCombos()
{
    //Image Combo
    UserDefinedObjectComponentVo voUserDefComp = getEditedComponent();
    if (voUserDefComp != null && voUserDefComp.getGraphicIsNotNull() && voUserDefComp.getGraphic().getImagesIsNotNull())
    {
        voUserDefComp.getGraphic().getImages().sort();
        for (int i = 0; i < voUserDefComp.getGraphic().getImages().size(); i++)
        {
            DrawingGraphicImageVo voImage = voUserDefComp.getGraphic().getImages().get(i);
            form.cmbImages().newRow(voImage, voImage.getImageName());
            if (i == 0)
                form.cmbImages().setValue(voImage);
        }
    }

    loadStatusCombo(false);
}
项目:openmaxims-linux    文件:Logic.java   
private void configureImageSelection(GraphicAssessmentVo config)
{
    configureTabs();

    for (int x = 0; x < config.getImages().size(); x++)
    {
        GenForm.lyrAssessmentLayer.tabSelectImageContainer.grdImagesRow row = form.lyrAssessment().tabSelectImage().grdImages().getRows().newRow();
        DrawingGraphicImageVo img = config.getImages().get(x);
        if (img != null)
        {
            String imageName = img.getImageName();
            row.setValue(img);
            row.setcolImage(imageName == null ? "?" : imageName);
        }
    }
}
项目:openmaxims-linux    文件:Logic.java   
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;
}