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

项目:AvoinApotti    文件:Logic.java   
private MedicationUnitVoCollection getUnits(DynamicGridRowCollection rows)
{
    if (rows == null)
        return null;
    MedicationUnitVoCollection result = new MedicationUnitVoCollection();
    for ( int i = 0 ; i  < rows.size() ; i++)
    {
        if (rows.get(i).getValue() instanceof MedicationUnitVo)
        {
            MedicationUnitVo x = (MedicationUnitVo) rows.get(i).getValue();
            if (x.getDoseUnitIsNotNull())
                result.add(x);
        }
    }
    if (result.size()==0)
        return null;
    return result;
}
项目:AvoinApotti    文件:Logic.java   
private void removeSelectedRow()
{

    DynamicGridRow row = form.lyrDetails().tabFRU().dyngrdFRU().getSelectedRow();
    if (row == null)
        return;
    Object rowValue =row.getValue();
    DynamicGridRow parent = row.getParent();
    form.lyrDetails().tabFRU().dyngrdFRU().getRows().remove(row);
    if (rowValue  instanceof MedicationFormVo)
        rebindFormRows();
    else if (rowValue instanceof MedicationRouteVo)
        rebindRouteRows(parent);
    else if (rowValue instanceof MedicationUnitVo)
        rebindUnitRows(parent);

}
项目:openMAXIMS    文件:Logic.java   
private MedicationUnitVoCollection getUnits(DynamicGridRowCollection rows)
{
    if (rows == null)
        return null;
    MedicationUnitVoCollection result = new MedicationUnitVoCollection();
    for ( int i = 0 ; i  < rows.size() ; i++)
    {
        if (rows.get(i).getValue() instanceof MedicationUnitVo)
        {
            MedicationUnitVo x = (MedicationUnitVo) rows.get(i).getValue();
            if (x.getDoseUnitIsNotNull())
                result.add(x);
        }
    }
    if (result.size()==0)
        return null;
    return result;
}
项目:openMAXIMS    文件:Logic.java   
private void removeSelectedRow()
{

    DynamicGridRow row = form.lyrDetails().tabFRU().dyngrdFRU().getSelectedRow();
    if (row == null)
        return;
    Object rowValue =row.getValue();
    DynamicGridRow parent = row.getParent();
    form.lyrDetails().tabFRU().dyngrdFRU().getRows().remove(row);
    if (rowValue  instanceof MedicationFormVo)
        rebindFormRows();
    else if (rowValue instanceof MedicationRouteVo)
        rebindRouteRows(parent);
    else if (rowValue instanceof MedicationUnitVo)
        rebindUnitRows(parent);

}
项目:openMAXIMS    文件:Logic.java   
private MedicationUnitVoCollection getUnits(DynamicGridRowCollection rows)
{
    if (rows == null)
        return null;
    MedicationUnitVoCollection result = new MedicationUnitVoCollection();
    for ( int i = 0 ; i  < rows.size() ; i++)
    {
        if (rows.get(i).getValue() instanceof MedicationUnitVo)
        {
            MedicationUnitVo x = (MedicationUnitVo) rows.get(i).getValue();
            if (x.getDoseUnitIsNotNull())
                result.add(x);
        }
    }
    if (result.size()==0)
        return null;
    return result;
}
项目:openMAXIMS    文件:Logic.java   
private void removeSelectedRow()
{

    DynamicGridRow row = form.lyrDetails().tabFRU().dyngrdFRU().getSelectedRow();
    if (row == null)
        return;
    Object rowValue =row.getValue();
    DynamicGridRow parent = row.getParent();
    form.lyrDetails().tabFRU().dyngrdFRU().getRows().remove(row);
    if (rowValue  instanceof MedicationFormVo)
        rebindFormRows();
    else if (rowValue instanceof MedicationRouteVo)
        rebindRouteRows(parent);
    else if (rowValue instanceof MedicationUnitVo)
        rebindUnitRows(parent);

}
项目:openmaxims-linux    文件:Logic.java   
private MedicationUnitVoCollection getUnits(DynamicGridRowCollection rows)
{
    if (rows == null)
        return null;
    MedicationUnitVoCollection result = new MedicationUnitVoCollection();
    for ( int i = 0 ; i  < rows.size() ; i++)
    {
        if (rows.get(i).getValue() instanceof MedicationUnitVo)
        {
            MedicationUnitVo x = (MedicationUnitVo) rows.get(i).getValue();
            if (x.getDoseUnitIsNotNull())
                result.add(x);
        }
    }
    if (result.size()==0)
        return null;
    return result;
}
项目:openmaxims-linux    文件:Logic.java   
private void removeSelectedRow()
{

    DynamicGridRow row = form.lyrDetails().tabFRU().dyngrdFRU().getSelectedRow();
    if (row == null)
        return;
    Object rowValue =row.getValue();
    DynamicGridRow parent = row.getParent();
    form.lyrDetails().tabFRU().dyngrdFRU().getRows().remove(row);
    if (rowValue  instanceof MedicationFormVo)
        rebindFormRows();
    else if (rowValue instanceof MedicationRouteVo)
        rebindRouteRows(parent);
    else if (rowValue instanceof MedicationUnitVo)
        rebindUnitRows(parent);

}
项目:AvoinApotti    文件:Logic.java   
private void rebindUnitRows(DynamicGridRow parent)
{
    if (parent == null)
        return;
    DynamicGridRowCollection rows = parent.getRows();
    MedicationDoseUnitCollection mRoutes = ims.core.vo.lookups.LookupHelper.getMedicationDoseUnit(this.domain.getLookupService());
    for (int i = 0 ; i < rows.size() ; i++)
    {
        if (rows.get(i).getValue() instanceof MedicationUnitVo)
        {
            MedicationUnitVo x = (MedicationUnitVo) rows.get(i).getValue();
            if (!x.getDoseUnitIsNotNull())
                continue;
            mRoutes.remove(x.getDoseUnit());
        }   
    }
    for (int i = 0 ; i < rows.size() ; i++)
    {
        DynamicGridCell cell = rows.get(i).getCells().get(form.lyrDetails().tabFRU().dyngrdFRU().getColumns().getByIdentifier(COL_MAIN));
        Object back = cell.getValue();
        cell.getItems().clear();
        if (back!=null)
            cell.getItems().newItem(back);
        for (int j = 0 ; j < mRoutes.size() ;j++)
            cell.getItems().newItem(mRoutes.get(j));
        cell.setValue(back);
    }

}
项目:openMAXIMS    文件:Logic.java   
private void rebindUnitRows(DynamicGridRow parent)
{
    if (parent == null)
        return;
    DynamicGridRowCollection rows = parent.getRows();
    MedicationDoseUnitCollection mRoutes = ims.core.vo.lookups.LookupHelper.getMedicationDoseUnit(this.domain.getLookupService());
    for (int i = 0 ; i < rows.size() ; i++)
    {
        if (rows.get(i).getValue() instanceof MedicationUnitVo)
        {
            MedicationUnitVo x = (MedicationUnitVo) rows.get(i).getValue();
            if (!x.getDoseUnitIsNotNull())
                continue;
            mRoutes.remove(x.getDoseUnit());
        }   
    }
    for (int i = 0 ; i < rows.size() ; i++)
    {
        DynamicGridCell cell = rows.get(i).getCells().get(form.lyrDetails().tabFRU().dyngrdFRU().getColumns().getByIdentifier(COL_MAIN));
        Object back = cell.getValue();
        cell.getItems().clear();
        if (back!=null)
            cell.getItems().newItem(back);
        for (int j = 0 ; j < mRoutes.size() ;j++)
            cell.getItems().newItem(mRoutes.get(j));
        cell.setValue(back);
    }

}
项目:openMAXIMS    文件:Logic.java   
private void rebindUnitRows(DynamicGridRow parent)
{
    if (parent == null)
        return;
    DynamicGridRowCollection rows = parent.getRows();
    MedicationDoseUnitCollection mRoutes = ims.core.vo.lookups.LookupHelper.getMedicationDoseUnit(this.domain.getLookupService());
    for (int i = 0 ; i < rows.size() ; i++)
    {
        if (rows.get(i).getValue() instanceof MedicationUnitVo)
        {
            MedicationUnitVo x = (MedicationUnitVo) rows.get(i).getValue();
            if (!x.getDoseUnitIsNotNull())
                continue;
            mRoutes.remove(x.getDoseUnit());
        }   
    }
    for (int i = 0 ; i < rows.size() ; i++)
    {
        DynamicGridCell cell = rows.get(i).getCells().get(form.lyrDetails().tabFRU().dyngrdFRU().getColumns().getByIdentifier(COL_MAIN));
        Object back = cell.getValue();
        cell.getItems().clear();
        if (back!=null)
            cell.getItems().newItem(back);
        for (int j = 0 ; j < mRoutes.size() ;j++)
            cell.getItems().newItem(mRoutes.get(j));
        cell.setValue(back);
    }

}
项目:openmaxims-linux    文件:Logic.java   
private void rebindUnitRows(DynamicGridRow parent)
{
    if (parent == null)
        return;
    DynamicGridRowCollection rows = parent.getRows();
    MedicationDoseUnitCollection mRoutes = ims.core.vo.lookups.LookupHelper.getMedicationDoseUnit(this.domain.getLookupService());
    for (int i = 0 ; i < rows.size() ; i++)
    {
        if (rows.get(i).getValue() instanceof MedicationUnitVo)
        {
            MedicationUnitVo x = (MedicationUnitVo) rows.get(i).getValue();
            if (!x.getDoseUnitIsNotNull())
                continue;
            mRoutes.remove(x.getDoseUnit());
        }   
    }
    for (int i = 0 ; i < rows.size() ; i++)
    {
        DynamicGridCell cell = rows.get(i).getCells().get(form.lyrDetails().tabFRU().dyngrdFRU().getColumns().getByIdentifier(COL_MAIN));
        Object back = cell.getValue();
        cell.getItems().clear();
        if (back!=null)
            cell.getItems().newItem(back);
        for (int j = 0 ; j < mRoutes.size() ;j++)
            cell.getItems().newItem(mRoutes.get(j));
        cell.setValue(back);
    }

}