Java 类ims.ocrr.vo.InvestigationIndexShortVoCollection 实例源码

项目:AvoinApotti    文件:Logic.java   
private void populateScreenFromData(InvestigationIndexShortVoCollection coll)
{
    for (int i = 0; i < coll.size(); i++)
    {
        InvestigationIndexShortVo item = coll.get(i);

        GenForm.grdTestsRow row = form.grdTests().getRows().newRow();

        row.setcolImage(form.getImages().OCRR.Investigation);
        row.setcolName(item.getName());
        row.setcolDescription(item.getDescription());
        if (item.getColourIsNotNull())
        {
            Color color = Color.getColor(item.getColour().getName());
            if (color != null)
                row.setcolColour(color.getImage());
        }
        row.setcolCategory(item.getCategoryIsNotNull() ? item.getCategory().getText() : "");

        if (item.getActiveStatusIsNotNull())
            row.setcolStatus(item.getActiveStatus().getText());
        row.setValue(item);
    }
}
项目:AvoinApotti    文件:Logic.java   
protected void onGrdTestsGridHeaderClicked(int column) throws PresentationLogicException
{
    if (column == 4)
    {
        if (form.getLocalContext().getSortOrder() == null)
        {
            form.getLocalContext().setSortOrder(SortOrder.ASCENDING);
        }

        InvestigationIndexShortVoCollection voCollInIndexShort = form.grdTests().getValues();
        voCollInIndexShort.sort(InvestigationIndexShortVo.getColourComparator(form.getLocalContext().getSortOrder()));

        if (form.getLocalContext().getSortOrder().equals(SortOrder.ASCENDING))
            form.getLocalContext().setSortOrder(SortOrder.DESCENDING);
        else if (form.getLocalContext().getSortOrder().equals(SortOrder.DESCENDING))
            form.getLocalContext().setSortOrder(SortOrder.ASCENDING);

        form.grdTests().getRows().clear();
        populateScreenFromData(voCollInIndexShort);
    }
}
项目:AvoinApotti    文件:Logic.java   
private void populateScreenFromData(InvestigationIndexShortVoCollection coll)
{   
    for(int i = 0; i < coll.size(); i++)
    {
        InvestigationIndexShortVo item = coll.get(i);

        GenForm.grdProfilesRow row = form.grdProfiles().getRows().newRow();

        row.setcolImage(form.getImages().OCRR.Profile);
        row.setcolName(item.getName());
        row.setcolDescription(item.getDescription());
        if(item.getColourIsNotNull())
        {
            Color color = Color.getColor(item.getColour().getName());
            if(color != null)
                row.setcolColour(color.getImage());
        }
        row.setcolCategory(item.getCategoryIsNotNull() ? item.getCategory().getText() : "");
        row.setcolStatus(item.getActiveStatusIsNotNull() ? item.getActiveStatus().getText() : "");
        row.setValue(item);
    }
}
项目:AvoinApotti    文件:Logic.java   
protected void onGrdProfilesGridHeaderClicked(int column) throws PresentationLogicException 
{
    if(column == 4)
    {
        if(form.getLocalContext().getSortOrder() == null)
        {
            form.getLocalContext().setSortOrder(SortOrder.ASCENDING);
        }

        InvestigationIndexShortVoCollection voCollInIndexShort = form.grdProfiles().getValues();    
        voCollInIndexShort.sort(InvestigationIndexShortVo.getColourComparator(form.getLocalContext().getSortOrder()));

        if(form.getLocalContext().getSortOrder().equals(SortOrder.ASCENDING))
            form.getLocalContext().setSortOrder(SortOrder.DESCENDING);
        else if(form.getLocalContext().getSortOrder().equals(SortOrder.DESCENDING))
            form.getLocalContext().setSortOrder(SortOrder.ASCENDING);

        form.grdProfiles().getRows().clear();
        populateScreenFromData(voCollInIndexShort);
    }
}
项目:openMAXIMS    文件:Logic.java   
private void populateScreenFromData(InvestigationIndexShortVoCollection coll)
{
    for (int i = 0; i < coll.size(); i++)
    {
        InvestigationIndexShortVo item = coll.get(i);

        GenForm.grdTestsRow row = form.grdTests().getRows().newRow();

        row.setcolImage(form.getImages().OCRR.Investigation);
        row.setcolName(item.getName());
        row.setcolDescription(item.getDescription());
        if (item.getColourIsNotNull())
        {
            Color color = Color.getColor(item.getColour().getName());
            if (color != null)
                row.setcolColour(color.getImage());
        }
        row.setcolCategory(item.getCategoryIsNotNull() ? item.getCategory().getText() : "");

        if (item.getActiveStatusIsNotNull())
            row.setcolStatus(item.getActiveStatus().getText());
        row.setValue(item);
    }
}
项目:openMAXIMS    文件:Logic.java   
protected void onGrdTestsGridHeaderClicked(int column) throws PresentationLogicException
{
    if (column == 4)
    {
        if (form.getLocalContext().getSortOrder() == null)
        {
            form.getLocalContext().setSortOrder(SortOrder.ASCENDING);
        }

        InvestigationIndexShortVoCollection voCollInIndexShort = form.grdTests().getValues();
        voCollInIndexShort.sort(InvestigationIndexShortVo.getColourComparator(form.getLocalContext().getSortOrder()));

        if (form.getLocalContext().getSortOrder().equals(SortOrder.ASCENDING))
            form.getLocalContext().setSortOrder(SortOrder.DESCENDING);
        else if (form.getLocalContext().getSortOrder().equals(SortOrder.DESCENDING))
            form.getLocalContext().setSortOrder(SortOrder.ASCENDING);

        form.grdTests().getRows().clear();
        populateScreenFromData(voCollInIndexShort);
    }
}
项目:openMAXIMS    文件:Logic.java   
private void populateScreenFromData(InvestigationIndexShortVoCollection coll)
{   
    for(int i = 0; i < coll.size(); i++)
    {
        InvestigationIndexShortVo item = coll.get(i);

        GenForm.grdProfilesRow row = form.grdProfiles().getRows().newRow();

        row.setcolImage(form.getImages().OCRR.Profile);
        row.setcolName(item.getName());
        row.setcolDescription(item.getDescription());
        if(item.getColourIsNotNull())
        {
            Color color = Color.getColor(item.getColour().getName());
            if(color != null)
                row.setcolColour(color.getImage());
        }
        row.setcolCategory(item.getCategoryIsNotNull() ? item.getCategory().getText() : "");
        row.setcolStatus(item.getActiveStatusIsNotNull() ? item.getActiveStatus().getText() : "");
        row.setValue(item);
    }
}
项目:openMAXIMS    文件:Logic.java   
protected void onGrdProfilesGridHeaderClicked(int column) throws PresentationLogicException 
{
    if(column == 4)
    {
        if(form.getLocalContext().getSortOrder() == null)
        {
            form.getLocalContext().setSortOrder(SortOrder.ASCENDING);
        }

        InvestigationIndexShortVoCollection voCollInIndexShort = form.grdProfiles().getValues();    
        voCollInIndexShort.sort(InvestigationIndexShortVo.getColourComparator(form.getLocalContext().getSortOrder()));

        if(form.getLocalContext().getSortOrder().equals(SortOrder.ASCENDING))
            form.getLocalContext().setSortOrder(SortOrder.DESCENDING);
        else if(form.getLocalContext().getSortOrder().equals(SortOrder.DESCENDING))
            form.getLocalContext().setSortOrder(SortOrder.ASCENDING);

        form.grdProfiles().getRows().clear();
        populateScreenFromData(voCollInIndexShort);
    }
}
项目:openMAXIMS    文件:Logic.java   
private void populateScreenFromData(InvestigationIndexShortVoCollection coll)
{
    for (int i = 0; i < coll.size(); i++)
    {
        InvestigationIndexShortVo item = coll.get(i);

        GenForm.grdTestsRow row = form.grdTests().getRows().newRow();

        row.setcolImage(form.getImages().OCRR.Investigation);
        row.setcolName(item.getName());
        row.setcolDescription(item.getDescription());
        if (item.getColourIsNotNull())
        {
            Color color = Color.getColor(item.getColour().getName());
            if (color != null)
                row.setcolColour(color.getImage());
        }
        row.setcolCategory(item.getCategoryIsNotNull() ? item.getCategory().getText() : "");

        if (item.getActiveStatusIsNotNull())
            row.setcolStatus(item.getActiveStatus().getText());
        row.setValue(item);
    }
}
项目:openMAXIMS    文件:Logic.java   
protected void onGrdTestsGridHeaderClicked(int column) throws PresentationLogicException
{
    if (column == 4)
    {
        if (form.getLocalContext().getSortOrder() == null)
        {
            form.getLocalContext().setSortOrder(SortOrder.ASCENDING);
        }

        InvestigationIndexShortVoCollection voCollInIndexShort = form.grdTests().getValues();
        voCollInIndexShort.sort(InvestigationIndexShortVo.getColourComparator(form.getLocalContext().getSortOrder()));

        if (form.getLocalContext().getSortOrder().equals(SortOrder.ASCENDING))
            form.getLocalContext().setSortOrder(SortOrder.DESCENDING);
        else if (form.getLocalContext().getSortOrder().equals(SortOrder.DESCENDING))
            form.getLocalContext().setSortOrder(SortOrder.ASCENDING);

        form.grdTests().getRows().clear();
        populateScreenFromData(voCollInIndexShort);
    }
}
项目:openMAXIMS    文件:Logic.java   
private void populateScreenFromData(InvestigationIndexShortVoCollection coll)
{   
    for(int i = 0; i < coll.size(); i++)
    {
        InvestigationIndexShortVo item = coll.get(i);

        GenForm.grdProfilesRow row = form.grdProfiles().getRows().newRow();

        row.setcolImage(form.getImages().OCRR.Profile);
        row.setcolName(item.getName());
        row.setcolDescription(item.getDescription());
        if(item.getColourIsNotNull())
        {
            Color color = Color.getColor(item.getColour().getName());
            if(color != null)
                row.setcolColour(color.getImage());
        }
        row.setcolCategory(item.getCategoryIsNotNull() ? item.getCategory().getText() : "");
        row.setcolStatus(item.getActiveStatusIsNotNull() ? item.getActiveStatus().getText() : "");
        row.setValue(item);
    }
}
项目:openMAXIMS    文件:Logic.java   
protected void onGrdProfilesGridHeaderClicked(int column) throws PresentationLogicException 
{
    if(column == 4)
    {
        if(form.getLocalContext().getSortOrder() == null)
        {
            form.getLocalContext().setSortOrder(SortOrder.ASCENDING);
        }

        InvestigationIndexShortVoCollection voCollInIndexShort = form.grdProfiles().getValues();    
        voCollInIndexShort.sort(InvestigationIndexShortVo.getColourComparator(form.getLocalContext().getSortOrder()));

        if(form.getLocalContext().getSortOrder().equals(SortOrder.ASCENDING))
            form.getLocalContext().setSortOrder(SortOrder.DESCENDING);
        else if(form.getLocalContext().getSortOrder().equals(SortOrder.DESCENDING))
            form.getLocalContext().setSortOrder(SortOrder.ASCENDING);

        form.grdProfiles().getRows().clear();
        populateScreenFromData(voCollInIndexShort);
    }
}
项目:openmaxims-linux    文件:Logic.java   
private void populateScreenFromData(InvestigationIndexShortVoCollection coll)
{
    for (int i = 0; i < coll.size(); i++)
    {
        InvestigationIndexShortVo item = coll.get(i);

        GenForm.grdTestsRow row = form.grdTests().getRows().newRow();

        row.setcolImage(form.getImages().OCRR.Investigation);
        row.setcolName(item.getName());
        row.setcolDescription(item.getDescription());
        if (item.getColourIsNotNull())
        {
            Color color = Color.getColor(item.getColour().getName());
            if (color != null)
                row.setcolColour(color.getImage());
        }
        row.setcolCategory(item.getCategoryIsNotNull() ? item.getCategory().getText() : "");

        if (item.getActiveStatusIsNotNull())
            row.setcolStatus(item.getActiveStatus().getText());
        row.setValue(item);
    }
}
项目:openmaxims-linux    文件:Logic.java   
protected void onGrdTestsGridHeaderClicked(int column) throws PresentationLogicException
{
    if (column == 4)
    {
        if (form.getLocalContext().getSortOrder() == null)
        {
            form.getLocalContext().setSortOrder(SortOrder.ASCENDING);
        }

        InvestigationIndexShortVoCollection voCollInIndexShort = form.grdTests().getValues();
        voCollInIndexShort.sort(InvestigationIndexShortVo.getColourComparator(form.getLocalContext().getSortOrder()));

        if (form.getLocalContext().getSortOrder().equals(SortOrder.ASCENDING))
            form.getLocalContext().setSortOrder(SortOrder.DESCENDING);
        else if (form.getLocalContext().getSortOrder().equals(SortOrder.DESCENDING))
            form.getLocalContext().setSortOrder(SortOrder.ASCENDING);

        form.grdTests().getRows().clear();
        populateScreenFromData(voCollInIndexShort);
    }
}
项目:openmaxims-linux    文件:Logic.java   
private void populateScreenFromData(InvestigationIndexShortVoCollection coll)
{   
    for(int i = 0; i < coll.size(); i++)
    {
        InvestigationIndexShortVo item = coll.get(i);

        GenForm.grdProfilesRow row = form.grdProfiles().getRows().newRow();

        row.setcolImage(form.getImages().OCRR.Profile);
        row.setcolName(item.getName());
        row.setcolDescription(item.getDescription());
        if(item.getColourIsNotNull())
        {
            Color color = Color.getColor(item.getColour().getName());
            if(color != null)
                row.setcolColour(color.getImage());
        }
        row.setcolCategory(item.getCategoryIsNotNull() ? item.getCategory().getText() : "");
        row.setcolStatus(item.getActiveStatusIsNotNull() ? item.getActiveStatus().getText() : "");
        row.setValue(item);
    }
}
项目:openmaxims-linux    文件:Logic.java   
protected void onGrdProfilesGridHeaderClicked(int column) throws PresentationLogicException 
{
    if(column == 4)
    {
        if(form.getLocalContext().getSortOrder() == null)
        {
            form.getLocalContext().setSortOrder(SortOrder.ASCENDING);
        }

        InvestigationIndexShortVoCollection voCollInIndexShort = form.grdProfiles().getValues();    
        voCollInIndexShort.sort(InvestigationIndexShortVo.getColourComparator(form.getLocalContext().getSortOrder()));

        if(form.getLocalContext().getSortOrder().equals(SortOrder.ASCENDING))
            form.getLocalContext().setSortOrder(SortOrder.DESCENDING);
        else if(form.getLocalContext().getSortOrder().equals(SortOrder.DESCENDING))
            form.getLocalContext().setSortOrder(SortOrder.ASCENDING);

        form.grdProfiles().getRows().clear();
        populateScreenFromData(voCollInIndexShort);
    }
}
项目:AvoinApotti    文件:Logic.java   
private void search()
{
    form.grdTests().getRows().clear();

    InvestigationProfileListSearchCriteriaVo searchCriteria = form.getGlobalContext().OCRR.getInvestigationListSearchCriteria();
    if (searchCriteria == null)
        return;

    if (!isValidSearchCriteria())
    {
        engine.showMessage("Please Enter Some Search Criteria");
        form.getGlobalContext().OCRR.setInvestigationListSearchCriteria(null);
        return;
    }

    InvestigationIndexShortVoCollection coll = null;
    if(form.txtCode().getValue()!=null)
        coll = domain.listInvestigationIndex(form.txtname().getValue(), form.txtCode().getValue(), form.cmbDiscipline().getValue(), form.cmbCategory().getValue(), form.cmbStatus().getValue(), Boolean.FALSE);
    else
        coll = domain.listInvestigationIndex(form.txtname().getValue(), form.cmbDiscipline().getValue(), form.cmbCategory().getValue(), form.cmbStatus().getValue(), Boolean.FALSE);

    form.grdTests().getRows().clear();

    if (coll == null)
    {
        engine.showMessage("There are no Records for the Search Criteria Provided");
        return;
    }

    if (coll.size() == 0)
    {
        engine.showMessage("There are no Records for the Search Criteria Provided");
        return;
    }

    populateScreenFromData(coll);
    changeContextMenuStatus();
}
项目:AvoinApotti    文件:Logic.java   
private void search()
{
    form.grdProfiles().getRows().clear();

    InvestigationProfileListSearchCriteriaVo searchCriteria = form.getGlobalContext().OCRR.getProfileListSearchCriteria();
    if(searchCriteria == null)
        return;

    if(!isValidSearchCriteria())
    {
        engine.showMessage("Please Enter Some Search Criteria");
        form.getGlobalContext().OCRR.setProfileListSearchCriteria(null);
        return;
    }   

    InvestigationIndexShortVoCollection coll = domain.listInvestigationIndex(form.txtname().getValue(), form.cmbDiscipline().getValue(), form.cmbCategory().getValue(), form.cmbStatus().getValue(), Boolean.TRUE);

    form.grdProfiles().getRows().clear();

    if(coll == null)
    {
        engine.showMessage("There are no Records for the Search Criteria Provided");
        return;
    }

    if(coll.size() == 0)
    {
        engine.showMessage("There are no Records for the Search Criteria Provided");
        return;
    }

    populateScreenFromData(coll);
    changeContextMenuStatus();
}
项目:AvoinApotti    文件:TestEditImpl.java   
public InvestigationIndexShortVoCollection listProfilesUsingInvestigation(InvestigationIndexRefVo invIndex)
{
    if (invIndex == null)
        throw new CodingRuntimeException("parameter invIndex is null in method listProfilesUsingInvestigation");

    DomainFactory factory = getDomainFactory();
    return InvestigationIndexShortVoAssembler.createInvestigationIndexShortVoCollectionFromInvestigationIndex(getAssociatedItems(factory, invIndex.getID_InvestigationIndex()));
}
项目:openMAXIMS    文件:Logic.java   
private void search()
{
    form.grdTests().getRows().clear();

    InvestigationProfileListSearchCriteriaVo searchCriteria = form.getGlobalContext().OCRR.getInvestigationListSearchCriteria();
    if (searchCriteria == null)
        return;

    if (!isValidSearchCriteria())
    {
        engine.showMessage("Please Enter Some Search Criteria");
        form.getGlobalContext().OCRR.setInvestigationListSearchCriteria(null);
        return;
    }

    InvestigationIndexShortVoCollection coll = null;
    if(form.txtCode().getValue()!=null)
        coll = domain.listInvestigationIndex(form.txtname().getValue(), form.txtCode().getValue(), form.cmbDiscipline().getValue(), form.cmbCategory().getValue(), form.cmbStatus().getValue(), Boolean.FALSE);
    else
        coll = domain.listInvestigationIndex(form.txtname().getValue(), form.cmbDiscipline().getValue(), form.cmbCategory().getValue(), form.cmbStatus().getValue(), Boolean.FALSE);

    form.grdTests().getRows().clear();

    if (coll == null)
    {
        engine.showMessage("There are no Records for the Search Criteria Provided");
        return;
    }

    if (coll.size() == 0)
    {
        engine.showMessage("There are no Records for the Search Criteria Provided");
        return;
    }

    populateScreenFromData(coll);
    changeContextMenuStatus();
}
项目:openMAXIMS    文件:Logic.java   
private void search()
{
    form.grdProfiles().getRows().clear();

    InvestigationProfileListSearchCriteriaVo searchCriteria = form.getGlobalContext().OCRR.getProfileListSearchCriteria();
    if(searchCriteria == null)
        return;

    if(!isValidSearchCriteria())
    {
        engine.showMessage("Please Enter Some Search Criteria");
        form.getGlobalContext().OCRR.setProfileListSearchCriteria(null);
        return;
    }   

    InvestigationIndexShortVoCollection coll = domain.listInvestigationIndex(form.txtname().getValue(), form.cmbDiscipline().getValue(), form.cmbCategory().getValue(), form.cmbStatus().getValue(), Boolean.TRUE);

    form.grdProfiles().getRows().clear();

    if(coll == null)
    {
        engine.showMessage("There are no Records for the Search Criteria Provided");
        return;
    }

    if(coll.size() == 0)
    {
        engine.showMessage("There are no Records for the Search Criteria Provided");
        return;
    }

    populateScreenFromData(coll);
    changeContextMenuStatus();
}
项目:openMAXIMS    文件:TestEditImpl.java   
public InvestigationIndexShortVoCollection listProfilesUsingInvestigation(InvestigationIndexRefVo invIndex)
{
    if (invIndex == null)
        throw new CodingRuntimeException("parameter invIndex is null in method listProfilesUsingInvestigation");

    DomainFactory factory = getDomainFactory();
    return InvestigationIndexShortVoAssembler.createInvestigationIndexShortVoCollectionFromInvestigationIndex(getAssociatedItems(factory, invIndex.getID_InvestigationIndex()));
}
项目:openMAXIMS    文件:Logic.java   
private void search()
{
    form.grdTests().getRows().clear();

    InvestigationProfileListSearchCriteriaVo searchCriteria = form.getGlobalContext().OCRR.getInvestigationListSearchCriteria();
    if (searchCriteria == null)
        return;

    if (!isValidSearchCriteria())
    {
        engine.showMessage("Please Enter Some Search Criteria");
        form.getGlobalContext().OCRR.setInvestigationListSearchCriteria(null);
        return;
    }

    InvestigationIndexShortVoCollection coll = null;
    if(form.txtCode().getValue()!=null)
        coll = domain.listInvestigationIndex(form.txtname().getValue(), form.txtCode().getValue(), form.cmbDiscipline().getValue(), form.cmbCategory().getValue(), form.cmbStatus().getValue(), Boolean.FALSE);
    else
        coll = domain.listInvestigationIndex(form.txtname().getValue(), form.cmbDiscipline().getValue(), form.cmbCategory().getValue(), form.cmbStatus().getValue(), Boolean.FALSE);

    form.grdTests().getRows().clear();

    if (coll == null)
    {
        engine.showMessage("There are no Records for the Search Criteria Provided");
        return;
    }

    if (coll.size() == 0)
    {
        engine.showMessage("There are no Records for the Search Criteria Provided");
        return;
    }

    populateScreenFromData(coll);
    changeContextMenuStatus();
}
项目:openMAXIMS    文件:Logic.java   
private void search()
{
    form.grdProfiles().getRows().clear();

    InvestigationProfileListSearchCriteriaVo searchCriteria = form.getGlobalContext().OCRR.getProfileListSearchCriteria();
    if(searchCriteria == null)
        return;

    if(!isValidSearchCriteria())
    {
        engine.showMessage("Please Enter Some Search Criteria");
        form.getGlobalContext().OCRR.setProfileListSearchCriteria(null);
        return;
    }   

    InvestigationIndexShortVoCollection coll = domain.listInvestigationIndex(form.txtname().getValue(), form.cmbDiscipline().getValue(), form.cmbCategory().getValue(), form.cmbStatus().getValue(), Boolean.TRUE);

    form.grdProfiles().getRows().clear();

    if(coll == null)
    {
        engine.showMessage("There are no Records for the Search Criteria Provided");
        return;
    }

    if(coll.size() == 0)
    {
        engine.showMessage("There are no Records for the Search Criteria Provided");
        return;
    }

    populateScreenFromData(coll);
    changeContextMenuStatus();
}
项目:openMAXIMS    文件:TestEditImpl.java   
public InvestigationIndexShortVoCollection listProfilesUsingInvestigation(InvestigationIndexRefVo invIndex)
{
    if (invIndex == null)
        throw new CodingRuntimeException("parameter invIndex is null in method listProfilesUsingInvestigation");

    DomainFactory factory = getDomainFactory();
    return InvestigationIndexShortVoAssembler.createInvestigationIndexShortVoCollectionFromInvestigationIndex(getAssociatedItems(factory, invIndex.getID_InvestigationIndex()));
}
项目:openmaxims-linux    文件:Logic.java   
private void search()
{
    form.grdTests().getRows().clear();

    InvestigationProfileListSearchCriteriaVo searchCriteria = form.getGlobalContext().OCRR.getInvestigationListSearchCriteria();
    if (searchCriteria == null)
        return;

    if (!isValidSearchCriteria())
    {
        engine.showMessage("Please Enter Some Search Criteria");
        form.getGlobalContext().OCRR.setInvestigationListSearchCriteria(null);
        return;
    }

    InvestigationIndexShortVoCollection coll = null;
    if(form.txtCode().getValue()!=null)
        coll = domain.listInvestigationIndex(form.txtname().getValue(), form.txtCode().getValue(), form.cmbDiscipline().getValue(), form.cmbCategory().getValue(), form.cmbStatus().getValue(), Boolean.FALSE);
    else
        coll = domain.listInvestigationIndex(form.txtname().getValue(), form.cmbDiscipline().getValue(), form.cmbCategory().getValue(), form.cmbStatus().getValue(), Boolean.FALSE);

    form.grdTests().getRows().clear();

    if (coll == null)
    {
        engine.showMessage("There are no Records for the Search Criteria Provided");
        return;
    }

    if (coll.size() == 0)
    {
        engine.showMessage("There are no Records for the Search Criteria Provided");
        return;
    }

    populateScreenFromData(coll);
    changeContextMenuStatus();
}
项目:openmaxims-linux    文件:Logic.java   
private void search()
{
    form.grdProfiles().getRows().clear();

    InvestigationProfileListSearchCriteriaVo searchCriteria = form.getGlobalContext().OCRR.getProfileListSearchCriteria();
    if(searchCriteria == null)
        return;

    if(!isValidSearchCriteria())
    {
        engine.showMessage("Please Enter Some Search Criteria");
        form.getGlobalContext().OCRR.setProfileListSearchCriteria(null);
        return;
    }   

    InvestigationIndexShortVoCollection coll = domain.listInvestigationIndex(form.txtname().getValue(), form.cmbDiscipline().getValue(), form.cmbCategory().getValue(), form.cmbStatus().getValue(), Boolean.TRUE);

    form.grdProfiles().getRows().clear();

    if(coll == null)
    {
        engine.showMessage("There are no Records for the Search Criteria Provided");
        return;
    }

    if(coll.size() == 0)
    {
        engine.showMessage("There are no Records for the Search Criteria Provided");
        return;
    }

    populateScreenFromData(coll);
    changeContextMenuStatus();
}
项目:openmaxims-linux    文件:TestEditImpl.java   
public InvestigationIndexShortVoCollection listProfilesUsingInvestigation(InvestigationIndexRefVo invIndex)
{
    if (invIndex == null)
        throw new CodingRuntimeException("parameter invIndex is null in method listProfilesUsingInvestigation");

    DomainFactory factory = getDomainFactory();
    return InvestigationIndexShortVoAssembler.createInvestigationIndexShortVoCollectionFromInvestigationIndex(getAssociatedItems(factory, invIndex.getID_InvestigationIndex()));
}
项目:AvoinApotti    文件:Logic.java   
/**
 * This method will show Templates/Profiles that are currently using the
 * investigation hence it could not be made inactive
 * 
 * @param errors
 */
private void displayConflictingRecords(ErrorCode[] errors)
{
    boolean tempError = false;
    boolean profError = false;

    if (errors != null && errors.length > 0)
    {
        for (int i = 0; i < errors.length; i++)
        {
            if (errors[i].equals(ErrorCode.ACTIVE_TEMPLATE_USING_INV))
                tempError = true;

            if (errors[i].equals(ErrorCode.ACTIVE_PROFILE_USING_INV))
                profError = true;
        }
    }

    String displayMessage = "";

    if (tempError == true)
    {
        OrderEntryTemplateShortVoCollection templates = domain.listTemplatesUsingInvestigation(form.getGlobalContext().OCRR.getSelectedTest());
        if (templates != null && templates.size() > 0)
        {
            displayMessage += "The following template(s) are using this Investigation, please remove the item from each template before making the Investigation inactive" + "\r";
            for (int i = 0; i < templates.size(); i++)
            {
                displayMessage += "\r" + templates.get(i).getDescription();
            }
        }
    }

    if (profError == true)
    {
        InvestigationIndexShortVoCollection profiles = domain.listProfilesUsingInvestigation(form.getGlobalContext().OCRR.getSelectedTest());
        if (profiles != null && profiles.size() > 0)
        {
            displayMessage += (tempError ? "\r" : "") + "The following profile(s) are using this Investigation, please remove the item from each profile before making the Investigation inactive" + "\r";
            for (int i = 0; i < profiles.size(); i++)
            {
                displayMessage += "\r" + profiles.get(i).getDescription();
            }
        }
    }

    engine.showMessage(displayMessage);
}
项目:AvoinApotti    文件:TestListImpl.java   
/**
* listInvestigationIndex
*/
public InvestigationIndexShortVoCollection listInvestigationIndex(String name, ServiceShortVo service,  Category categoryLookup, PreActiveActiveInactiveStatus status,Boolean isProfile)
{
    DomainFactory factory = getDomainFactory();

    String hql = " select distinct invIndex from InvestigationIndex invIndex "; 
    StringBuffer condStr = new StringBuffer();
    String andStr = " ";

    ArrayList markers = new ArrayList();
    ArrayList values = new ArrayList();

    // please ensure no other criteria goes above this search element///
    if(service != null)
    {
        condStr.append(andStr + " join invIndex.investigations as inv where inv.activeStatus.id <> :activeStatusId and inv.providerService.locationService.service.id = :idService");
        //WDEV-17025
        markers.add("activeStatusId");
        values.add(PreActiveActiveInactiveStatus.INACTIVE.getID());
            markers.add("idService");
        values.add(service.getID_Service());
        andStr = " and ";       
    }
    else
        andStr = " where ";
    ////////////////////////////////////////////////////////////////////

    if(name != null)
    {
        condStr.append(andStr + " invIndex.upperName like :name");
            markers.add("name");
        values.add(name.toUpperCase() + "%");
        andStr = " and ";   
    }   

    if(categoryLookup != null)
    {
        condStr.append(andStr + " invIndex.category = :category");
            markers.add("category");
        values.add(getDomLookup(categoryLookup));
        andStr = " and ";   
    }   

    if(isProfile != null)
    {
        condStr.append(andStr + " invIndex.isProfile = :isProfile");
        markers.add("isProfile");
        values.add(isProfile);
        andStr = " and ";
    }

    if(status != null)
    {
        condStr.append(andStr + " invIndex.activeStatus = :status");
        markers.add("status");
        values.add(getDomLookup(status));
        andStr = " and ";
    }

    hql += condStr.toString();
    return InvestigationIndexShortVoAssembler.createInvestigationIndexShortVoCollectionFromInvestigationIndex(factory.find(hql,markers,values)).sort();
}
项目:AvoinApotti    文件:TestListImpl.java   
/**
* listInvestigationIndex
*/
public InvestigationIndexShortVoCollection listInvestigationIndex(String name, String investigationCode, ServiceShortVo service, Category categoryLookup, PreActiveActiveInactiveStatus status, Boolean isProfile)
{
    DomainFactory factory = getDomainFactory();

    String hql = " select distinct invIndex from Investigation as inv left join inv.investigationIndex as invIndex"; 
    StringBuffer condStr = new StringBuffer();
    String andStr = " ";

    ArrayList<String> markers = new ArrayList<String>();
    ArrayList<Object> values = new ArrayList<Object>();

    // please ensure no other criteria goes above this search element///
    if (investigationCode != null)
    {
        condStr.append(andStr + " where inv.providerInvCode = :invCode");
        markers.add("invCode");
        values.add(investigationCode);
        andStr = " and ";
    }
    else
        andStr = " where ";
    ////////////////////////////////////////////////////////////////////

    if(name != null)
    {
        condStr.append(andStr + " invIndex.upperName like :name");
            markers.add("name");
        values.add(name.toUpperCase() + "%");
        andStr = " and ";   
    }

    if(categoryLookup != null)
    {
        condStr.append(andStr + " invIndex.category = :category");
            markers.add("category");
        values.add(getDomLookup(categoryLookup));
        andStr = " and ";   
    }   

    if(isProfile != null)
    {
        condStr.append(andStr + " invIndex.isProfile = :isProfile");
        markers.add("isProfile");
        values.add(isProfile);
        andStr = " and ";
    }

    if(status != null)
    {
        condStr.append(andStr + " invIndex.activeStatus = :status");
        markers.add("status");
        values.add(getDomLookup(status));
        andStr = " and ";
    }

    hql += condStr.toString();
    return InvestigationIndexShortVoAssembler.createInvestigationIndexShortVoCollectionFromInvestigationIndex(factory.find(hql,markers,values)).sort();
}
项目:openMAXIMS    文件:Logic.java   
/**
 * This method will show Templates/Profiles that are currently using the
 * investigation hence it could not be made inactive
 * 
 * @param errors
 */
private void displayConflictingRecords(ErrorCode[] errors)
{
    boolean tempError = false;
    boolean profError = false;

    if (errors != null && errors.length > 0)
    {
        for (int i = 0; i < errors.length; i++)
        {
            if (errors[i].equals(ErrorCode.ACTIVE_TEMPLATE_USING_INV))
                tempError = true;

            if (errors[i].equals(ErrorCode.ACTIVE_PROFILE_USING_INV))
                profError = true;
        }
    }

    String displayMessage = "";

    if (tempError == true)
    {
        OrderEntryTemplateShortVoCollection templates = domain.listTemplatesUsingInvestigation(form.getGlobalContext().OCRR.getSelectedTest());
        if (templates != null && templates.size() > 0)
        {
            displayMessage += "The following template(s) are using this Investigation, please remove the item from each template before making the Investigation inactive" + "\r";
            for (int i = 0; i < templates.size(); i++)
            {
                displayMessage += "\r" + templates.get(i).getDescription();
            }
        }
    }

    if (profError == true)
    {
        InvestigationIndexShortVoCollection profiles = domain.listProfilesUsingInvestigation(form.getGlobalContext().OCRR.getSelectedTest());
        if (profiles != null && profiles.size() > 0)
        {
            displayMessage += (tempError ? "\r" : "") + "The following profile(s) are using this Investigation, please remove the item from each profile before making the Investigation inactive" + "\r";
            for (int i = 0; i < profiles.size(); i++)
            {
                displayMessage += "\r" + profiles.get(i).getDescription();
            }
        }
    }

    engine.showMessage(displayMessage);
}
项目:openMAXIMS    文件:TestListImpl.java   
/**
* listInvestigationIndex
*/
public InvestigationIndexShortVoCollection listInvestigationIndex(String name, ServiceShortVo service,  Category categoryLookup, PreActiveActiveInactiveStatus status,Boolean isProfile)
{
    DomainFactory factory = getDomainFactory();

    String hql = " select distinct invIndex from InvestigationIndex invIndex "; 
    StringBuffer condStr = new StringBuffer();
    String andStr = " ";

    ArrayList markers = new ArrayList();
    ArrayList values = new ArrayList();

    // please ensure no other criteria goes above this search element///
    if(service != null)
    {
        condStr.append(andStr + " join invIndex.investigations as inv where inv.activeStatus.id <> :activeStatusId and inv.providerService.locationService.service.id = :idService");
        //WDEV-17025
        markers.add("activeStatusId");
        values.add(PreActiveActiveInactiveStatus.INACTIVE.getID());
            markers.add("idService");
        values.add(service.getID_Service());
        andStr = " and ";       
    }
    else
        andStr = " where ";
    ////////////////////////////////////////////////////////////////////

    if(name != null)
    {
        condStr.append(andStr + " invIndex.upperName like :name");
            markers.add("name");
        values.add(name.toUpperCase() + "%");
        andStr = " and ";   
    }   

    if(categoryLookup != null)
    {
        condStr.append(andStr + " invIndex.category = :category");
            markers.add("category");
        values.add(getDomLookup(categoryLookup));
        andStr = " and ";   
    }   

    if(isProfile != null)
    {
        condStr.append(andStr + " invIndex.isProfile = :isProfile");
        markers.add("isProfile");
        values.add(isProfile);
        andStr = " and ";
    }

    if(status != null)
    {
        condStr.append(andStr + " invIndex.activeStatus = :status");
        markers.add("status");
        values.add(getDomLookup(status));
        andStr = " and ";
    }

    hql += condStr.toString();
    return InvestigationIndexShortVoAssembler.createInvestigationIndexShortVoCollectionFromInvestigationIndex(factory.find(hql,markers,values)).sort();
}
项目:openMAXIMS    文件:TestListImpl.java   
/**
* listInvestigationIndex
*/
public InvestigationIndexShortVoCollection listInvestigationIndex(String name, String investigationCode, ServiceShortVo service, Category categoryLookup, PreActiveActiveInactiveStatus status, Boolean isProfile)
{
    DomainFactory factory = getDomainFactory();

    String hql = " select distinct invIndex from Investigation as inv left join inv.investigationIndex as invIndex"; 
    StringBuffer condStr = new StringBuffer();
    String andStr = " ";

    ArrayList<String> markers = new ArrayList<String>();
    ArrayList<Object> values = new ArrayList<Object>();

    // please ensure no other criteria goes above this search element///
    if (investigationCode != null)
    {
        condStr.append(andStr + " where inv.providerInvCode = :invCode");
        markers.add("invCode");
        values.add(investigationCode);
        andStr = " and ";
    }
    else
        andStr = " where ";
    ////////////////////////////////////////////////////////////////////

    if(name != null)
    {
        condStr.append(andStr + " invIndex.upperName like :name");
            markers.add("name");
        values.add(name.toUpperCase() + "%");
        andStr = " and ";   
    }

    if(categoryLookup != null)
    {
        condStr.append(andStr + " invIndex.category = :category");
            markers.add("category");
        values.add(getDomLookup(categoryLookup));
        andStr = " and ";   
    }   

    if(isProfile != null)
    {
        condStr.append(andStr + " invIndex.isProfile = :isProfile");
        markers.add("isProfile");
        values.add(isProfile);
        andStr = " and ";
    }

    if(status != null)
    {
        condStr.append(andStr + " invIndex.activeStatus = :status");
        markers.add("status");
        values.add(getDomLookup(status));
        andStr = " and ";
    }

    hql += condStr.toString();
    return InvestigationIndexShortVoAssembler.createInvestigationIndexShortVoCollectionFromInvestigationIndex(factory.find(hql,markers,values)).sort();
}
项目:openMAXIMS    文件:Logic.java   
/**
 * This method will show Templates/Profiles that are currently using the
 * investigation hence it could not be made inactive
 * 
 * @param errors
 */
private void displayConflictingRecords(ErrorCode[] errors)
{
    boolean tempError = false;
    boolean profError = false;

    if (errors != null && errors.length > 0)
    {
        for (int i = 0; i < errors.length; i++)
        {
            if (errors[i].equals(ErrorCode.ACTIVE_TEMPLATE_USING_INV))
                tempError = true;

            if (errors[i].equals(ErrorCode.ACTIVE_PROFILE_USING_INV))
                profError = true;
        }
    }

    String displayMessage = "";

    if (tempError == true)
    {
        OrderEntryTemplateShortVoCollection templates = domain.listTemplatesUsingInvestigation(form.getGlobalContext().OCRR.getSelectedTest());
        if (templates != null && templates.size() > 0)
        {
            displayMessage += "The following template(s) are using this Investigation, please remove the item from each template before making the Investigation inactive" + "\r";
            for (int i = 0; i < templates.size(); i++)
            {
                displayMessage += "\r" + templates.get(i).getDescription();
            }
        }
    }

    if (profError == true)
    {
        InvestigationIndexShortVoCollection profiles = domain.listProfilesUsingInvestigation(form.getGlobalContext().OCRR.getSelectedTest());
        if (profiles != null && profiles.size() > 0)
        {
            displayMessage += (tempError ? "\r" : "") + "The following profile(s) are using this Investigation, please remove the item from each profile before making the Investigation inactive" + "\r";
            for (int i = 0; i < profiles.size(); i++)
            {
                displayMessage += "\r" + profiles.get(i).getDescription();
            }
        }
    }

    engine.showMessage(displayMessage);
}
项目:openMAXIMS    文件:TestListImpl.java   
/**
* listInvestigationIndex
*/
public InvestigationIndexShortVoCollection listInvestigationIndex(String name, ServiceShortVo service,  Category categoryLookup, PreActiveActiveInactiveStatus status,Boolean isProfile)
{
    DomainFactory factory = getDomainFactory();

    String hql = " select distinct invIndex from InvestigationIndex invIndex "; 
    StringBuffer condStr = new StringBuffer();
    String andStr = " ";

    ArrayList markers = new ArrayList();
    ArrayList values = new ArrayList();

    // please ensure no other criteria goes above this search element///
    if(service != null)
    {
        condStr.append(andStr + " join invIndex.investigations as inv where inv.activeStatus.id <> :activeStatusId and inv.providerService.locationService.service.id = :idService");
        //WDEV-17025
        markers.add("activeStatusId");
        values.add(PreActiveActiveInactiveStatus.INACTIVE.getID());
            markers.add("idService");
        values.add(service.getID_Service());
        andStr = " and ";       
    }
    else
        andStr = " where ";
    ////////////////////////////////////////////////////////////////////

    if(name != null)
    {
        condStr.append(andStr + " invIndex.upperName like :name");
            markers.add("name");
        values.add(name.toUpperCase() + "%");
        andStr = " and ";   
    }   

    if(categoryLookup != null)
    {
        condStr.append(andStr + " invIndex.category = :category");
            markers.add("category");
        values.add(getDomLookup(categoryLookup));
        andStr = " and ";   
    }   

    if(isProfile != null)
    {
        condStr.append(andStr + " invIndex.isProfile = :isProfile");
        markers.add("isProfile");
        values.add(isProfile);
        andStr = " and ";
    }

    if(status != null)
    {
        condStr.append(andStr + " invIndex.activeStatus = :status");
        markers.add("status");
        values.add(getDomLookup(status));
        andStr = " and ";
    }

    hql += condStr.toString();
    return InvestigationIndexShortVoAssembler.createInvestigationIndexShortVoCollectionFromInvestigationIndex(factory.find(hql,markers,values)).sort();
}
项目:openMAXIMS    文件:TestListImpl.java   
/**
* listInvestigationIndex
*/
public InvestigationIndexShortVoCollection listInvestigationIndex(String name, String investigationCode, ServiceShortVo service, Category categoryLookup, PreActiveActiveInactiveStatus status, Boolean isProfile)
{
    DomainFactory factory = getDomainFactory();

    String hql = " select distinct invIndex from Investigation as inv left join inv.investigationIndex as invIndex"; 
    StringBuffer condStr = new StringBuffer();
    String andStr = " ";

    ArrayList<String> markers = new ArrayList<String>();
    ArrayList<Object> values = new ArrayList<Object>();

    // please ensure no other criteria goes above this search element///
    if (investigationCode != null)
    {
        condStr.append(andStr + " where inv.providerInvCode = :invCode");
        markers.add("invCode");
        values.add(investigationCode);
        andStr = " and ";
    }
    else
        andStr = " where ";
    ////////////////////////////////////////////////////////////////////

    if(name != null)
    {
        condStr.append(andStr + " invIndex.upperName like :name");
            markers.add("name");
        values.add(name.toUpperCase() + "%");
        andStr = " and ";   
    }

    if(categoryLookup != null)
    {
        condStr.append(andStr + " invIndex.category = :category");
            markers.add("category");
        values.add(getDomLookup(categoryLookup));
        andStr = " and ";   
    }   

    if(isProfile != null)
    {
        condStr.append(andStr + " invIndex.isProfile = :isProfile");
        markers.add("isProfile");
        values.add(isProfile);
        andStr = " and ";
    }

    if(status != null)
    {
        condStr.append(andStr + " invIndex.activeStatus = :status");
        markers.add("status");
        values.add(getDomLookup(status));
        andStr = " and ";
    }

    hql += condStr.toString();
    return InvestigationIndexShortVoAssembler.createInvestigationIndexShortVoCollectionFromInvestigationIndex(factory.find(hql,markers,values)).sort();
}
项目:openmaxims-linux    文件:Logic.java   
/**
 * This method will show Templates/Profiles that are currently using the
 * investigation hence it could not be made inactive
 * 
 * @param errors
 */
private void displayConflictingRecords(ErrorCode[] errors)
{
    boolean tempError = false;
    boolean profError = false;

    if (errors != null && errors.length > 0)
    {
        for (int i = 0; i < errors.length; i++)
        {
            if (errors[i].equals(ErrorCode.ACTIVE_TEMPLATE_USING_INV))
                tempError = true;

            if (errors[i].equals(ErrorCode.ACTIVE_PROFILE_USING_INV))
                profError = true;
        }
    }

    String displayMessage = "";

    if (tempError == true)
    {
        OrderEntryTemplateShortVoCollection templates = domain.listTemplatesUsingInvestigation(form.getGlobalContext().OCRR.getSelectedTest());
        if (templates != null && templates.size() > 0)
        {
            displayMessage += "The following template(s) are using this Investigation, please remove the item from each template before making the Investigation inactive" + "\r";
            for (int i = 0; i < templates.size(); i++)
            {
                displayMessage += "\r" + templates.get(i).getDescription();
            }
        }
    }

    if (profError == true)
    {
        InvestigationIndexShortVoCollection profiles = domain.listProfilesUsingInvestigation(form.getGlobalContext().OCRR.getSelectedTest());
        if (profiles != null && profiles.size() > 0)
        {
            displayMessage += (tempError ? "\r" : "") + "The following profile(s) are using this Investigation, please remove the item from each profile before making the Investigation inactive" + "\r";
            for (int i = 0; i < profiles.size(); i++)
            {
                displayMessage += "\r" + profiles.get(i).getDescription();
            }
        }
    }

    engine.showMessage(displayMessage);
}
项目:openmaxims-linux    文件:TestListImpl.java   
/**
* listInvestigationIndex
*/
public InvestigationIndexShortVoCollection listInvestigationIndex(String name, ServiceShortVo service,  Category categoryLookup, PreActiveActiveInactiveStatus status,Boolean isProfile)
{
    DomainFactory factory = getDomainFactory();

    String hql = " select distinct invIndex from InvestigationIndex invIndex "; 
    StringBuffer condStr = new StringBuffer();
    String andStr = " ";

    ArrayList markers = new ArrayList();
    ArrayList values = new ArrayList();

    // please ensure no other criteria goes above this search element///
    if(service != null)
    {
        condStr.append(andStr + " join invIndex.investigations as inv where inv.activeStatus.id <> :activeStatusId and inv.providerService.locationService.service.id = :idService");
        //WDEV-17025
        markers.add("activeStatusId");
        values.add(PreActiveActiveInactiveStatus.INACTIVE.getID());
            markers.add("idService");
        values.add(service.getID_Service());
        andStr = " and ";       
    }
    else
        andStr = " where ";
    ////////////////////////////////////////////////////////////////////

    if(name != null)
    {
        condStr.append(andStr + " invIndex.upperName like :name");
            markers.add("name");
        values.add(name.toUpperCase() + "%");
        andStr = " and ";   
    }   

    if(categoryLookup != null)
    {
        condStr.append(andStr + " invIndex.category = :category");
            markers.add("category");
        values.add(getDomLookup(categoryLookup));
        andStr = " and ";   
    }   

    if(isProfile != null)
    {
        condStr.append(andStr + " invIndex.isProfile = :isProfile");
        markers.add("isProfile");
        values.add(isProfile);
        andStr = " and ";
    }

    if(status != null)
    {
        condStr.append(andStr + " invIndex.activeStatus = :status");
        markers.add("status");
        values.add(getDomLookup(status));
        andStr = " and ";
    }

    hql += condStr.toString();
    return InvestigationIndexShortVoAssembler.createInvestigationIndexShortVoCollectionFromInvestigationIndex(factory.find(hql,markers,values)).sort();
}
项目:openmaxims-linux    文件:TestListImpl.java   
/**
* listInvestigationIndex
*/
public InvestigationIndexShortVoCollection listInvestigationIndex(String name, String investigationCode, ServiceShortVo service, Category categoryLookup, PreActiveActiveInactiveStatus status, Boolean isProfile)
{
    DomainFactory factory = getDomainFactory();

    String hql = " select distinct invIndex from Investigation as inv left join inv.investigationIndex as invIndex"; 
    StringBuffer condStr = new StringBuffer();
    String andStr = " ";

    ArrayList<String> markers = new ArrayList<String>();
    ArrayList<Object> values = new ArrayList<Object>();

    // please ensure no other criteria goes above this search element///
    if (investigationCode != null)
    {
        condStr.append(andStr + " where inv.providerInvCode = :invCode");
        markers.add("invCode");
        values.add(investigationCode);
        andStr = " and ";
    }
    else
        andStr = " where ";
    ////////////////////////////////////////////////////////////////////

    if(name != null)
    {
        condStr.append(andStr + " invIndex.upperName like :name");
            markers.add("name");
        values.add(name.toUpperCase() + "%");
        andStr = " and ";   
    }

    if(categoryLookup != null)
    {
        condStr.append(andStr + " invIndex.category = :category");
            markers.add("category");
        values.add(getDomLookup(categoryLookup));
        andStr = " and ";   
    }   

    if(isProfile != null)
    {
        condStr.append(andStr + " invIndex.isProfile = :isProfile");
        markers.add("isProfile");
        values.add(isProfile);
        andStr = " and ";
    }

    if(status != null)
    {
        condStr.append(andStr + " invIndex.activeStatus = :status");
        markers.add("status");
        values.add(getDomLookup(status));
        andStr = " and ";
    }

    hql += condStr.toString();
    return InvestigationIndexShortVoAssembler.createInvestigationIndexShortVoCollectionFromInvestigationIndex(factory.find(hql,markers,values)).sort();
}