Java 类ims.emergency.vo.TrackingAreaVoCollection 实例源码

项目:AvoinApotti    文件:Logic.java   
private void populateAreaCombo(LocationLiteVo value)
{
    form.cmbArea().clear();
    if (form.cmbEmergencyDep().getValue()==null)
        return;

    TrackingAreaVoCollection collAreas = domain.getTrackingAreasByLocation(form.cmbEmergencyDep().getValue());
    if (collAreas == null)
        return;

    for (int i = 0; i < collAreas.size(); i++)
    {
        form.cmbArea().newRow(collAreas.get(i), collAreas.get(i).getAreaDisplayName());
    }
    form.cmbArea().showOpened();
}
项目:AvoinApotti    文件:Logic.java   
private void populateGridToArea()
{
    //TrackingAreaVoCollection collAreas = domain.getAreasDefinitions(form.cmbFromArea().getValue().getEDLocation());
     TrackingConfigurationVo trackConfig = domain.getTrackingConfig(form.cmbFromArea().getValue().getEDLocation());

    if (trackConfig==null)
        return;

    TrackingAreaVoCollection collAreas = trackConfig.getAreas();

    if (collAreas==null)
        return;

    for (int i=0;i<collAreas.size();i++)
    {
        if (collAreas.get(i).getIsRegistrationArea() || collAreas.get(i).getIsOverallView() || (collAreas.get(i).getStatusIsNotNull() && PreActiveActiveInactiveStatus.INACTIVE.equals(collAreas.get(i).getStatus())))
            continue;

        if (!collAreas.get(i).equals(form.cmbFromArea().getValue()))
        {
            addRow(collAreas.get(i));
        }
    }
}
项目:AvoinApotti    文件:Logic.java   
public TrackingAreaVoCollection getValue()
{
    TrackingAreaVoCollection collectionToSave = new TrackingAreaVoCollection();

    if (form.getLocalContext().getTrackingAreaCollection() == null)
    {
        clear();
        addOverallView();
        addRegistrationArea();// FB
    }

    for (int i = 0; i < form.grdAreaDefinition().getRows().size(); i++)
    {
        collectionToSave.add(form.grdAreaDefinition().getValues().get(i));
    }

    if (form.getLocalContext().getRegistrationArea() != null)
    {
        collectionToSave.add(form.getLocalContext().getRegistrationArea());// FB
    }

    return collectionToSave;

}
项目:AvoinApotti    文件:Logic.java   
private void ListAwaitingClinicalImagingResult(ILocation currentLocation,TrackingAreaVoCollection areas)
{
    DynamicGridRow row = form.dyngrdAreas().getRows().newRow();
    DynamicGridCell cell = row.getCells().newCell(form.dyngrdAreas().getColumns().getByIdentifier(COL_STATUS), DynamicCellType.STRING);
    cell.setWidth(200);
    cell.setValue("Awaiting Clinical Imaging Result");
    cell.setBackColor(Color.fromRGB(198, 223, 242));                

    for(int i=0;i< areas.size();i++)
    {           
        cell = row.getCells().newCell(form.dyngrdAreas().getColumns().getByIdentifier(COL_AREA+areas.get(i).getID_TrackingArea()), DynamicCellType.STRING);
        cell.setWidth(150);
        //String val="";
        cell.setValue("-");
        //cell.setBackColor(Color.LightSteelBlue);          
    }

    cell = row.getCells().newCell(form.dyngrdAreas().getColumns().getByIdentifier(COL_OVERALL), DynamicCellType.HTMLVIEW);
    cell.setWidth(90);
    cell.setValue("<b>-</B>");
    cell.setBackColor(Color.Bisque);
}
项目:AvoinApotti    文件:Logic.java   
private void ListAwaitingPathologyResult(ILocation currentLocation,TrackingAreaVoCollection areas)
{
    DynamicGridRow row = form.dyngrdAreas().getRows().newRow();
    DynamicGridCell cell = row.getCells().newCell(form.dyngrdAreas().getColumns().getByIdentifier(COL_STATUS), DynamicCellType.STRING);
    cell.setWidth(150);
    cell.setValue("Awaiting Pathology Result");
    cell.setBackColor(Color.fromRGB(198, 223, 242));

    for(int i=0;i< areas.size();i++)
    {           
        cell = row.getCells().newCell(form.dyngrdAreas().getColumns().getByIdentifier(COL_AREA+areas.get(i).getID_TrackingArea()), DynamicCellType.STRING);
        cell.setWidth(150);
        //String val="";
        cell.setValue("-");
        //cell.setBackColor(Color.LightSteelBlue);          
    }

    cell = row.getCells().newCell(form.dyngrdAreas().getColumns().getByIdentifier(COL_OVERALL), DynamicCellType.HTMLVIEW);
    cell.setWidth(90);
    cell.setValue("<b>-</B>");
    cell.setBackColor(Color.Bisque);
}
项目:AvoinApotti    文件:Logic.java   
private void populateAreasRows(TrackingAreaVoCollection areas, ILocation currentLocation) {
    // TODO Auto-generated method stub

    ListAwaitingTriageCounts(areas,currentLocation);
    ListPrioritiesCounts(currentLocation,areas, "Priority 1", ims.emergency.vo.lookups.TriagePriority.PRIORITY1);
    ListPrioritiesCounts(currentLocation,areas, "Priority 2",ims.emergency.vo.lookups.TriagePriority.PRIORITY2);
    ListPrioritiesCounts(currentLocation,areas, "Priority 3",ims.emergency.vo.lookups.TriagePriority.PRIORITY3);
    ListPrioritiesCounts(currentLocation,areas, "Priority 4",ims.emergency.vo.lookups.TriagePriority.PRIORITY4);    
    ListPrioritiesCounts(currentLocation,areas, "Priority 5",ims.emergency.vo.lookups.TriagePriority.PRIORITY5);
    ListUnallocated(currentLocation,areas);
    ListAllocated(currentLocation,areas);
    ListReferredToSpecialty(currentLocation,areas);
    ListAwaitingClinicalImagingResult(currentLocation,areas);
    ListAwaitingPathologyResult(currentLocation,areas);
    List15MinLOSBreached(currentLocation,areas);
    ListLOSBreached(currentLocation,areas);
    ListAverageLengthOfStay(currentLocation,areas);
    ListTotalPatientsOnArea(currentLocation,areas);

}
项目:AvoinApotti    文件:Logic.java   
private void populateGrid()
{
    form.grdConfig().getRows().clear();

    if (form.getGlobalContext().Emergency.getTrackingArea() == null)
        return;
    else if (form.getGlobalContext().Emergency.getTrackingArea().getSendToAreas() == null)
        return;

    TrackingAreaVoCollection collToArea = form.getGlobalContext().Emergency.getTrackingArea().getSendToAreas();

    for (int i = 0; i < collToArea.size(); i++)
    {
        grdConfigRow row = form.grdConfig().getRows().newRow();
        row.setcolArea(collToArea.get(i).getAreaDisplayName());
        row.setValue(collToArea.get(i));
    }
}
项目:AvoinApotti    文件:Logic.java   
public void initialize(Boolean argument, TrackingAreaVoCollection areaDefCollection)
{
    if (argument && areaDefCollection == null && form.cmbArea().getValue() != null) // Send To Config Menu
    {
        form.getGlobalContext().Emergency.setTrackingArea(domain.getTrackingArea(form.cmbArea().getValue()));
        engine.open(form.getForms().Emergency.SendToConfigDialog);
    }
    else if (areaDefCollection != null) // view Mode
    {
        populateFromAreaCombo(areaDefCollection);
        form.getGlobalContext().Emergency.setTrackingArea(null);
    }
    else if (!argument && areaDefCollection == null) // if TrackingConfiguration does not have any Area Definitions
    {
        form.getGlobalContext().Emergency.setTrackingArea(null);
    }
    open();
}
项目:AvoinApotti    文件:EDWorkloadSummaryImpl.java   
public TrackingAreaVoCollection getAreas(ILocation location) 
{
    if (location == null )
    {
        throw new CodingRuntimeException("Cannot get Location on null Id ");
    }

    DomainFactory factory = getDomainFactory();

    StringBuffer hql = new StringBuffer();

    hql.append("select  t2_1 ");
    hql.append(" from TrackingConfiguration as t1_1 left join t1_1.eDLocation as l1_1 left join t1_1.areas as t2_1 left join t2_1.status as l2_1");
    hql.append(" where ");
    hql.append("(l1_1.id = :Location_id and t1_1.isActive = 1 and l2_1.id = :lookup_inst and  (t2_1.isOverallView = 0 or t2_1.isOverallView is null ))");

    List<?> list = factory.find(hql.toString(), new String[] {"Location_id","lookup_inst"}, new Object[] {location.getID(),ims.core.vo.lookups.PreActiveActiveInactiveStatus.ACTIVE.getID()});

    return TrackingAreaVoAssembler.createTrackingAreaVoCollectionFromTrackingArea(list);
}
项目:openMAXIMS    文件:Logic.java   
private void populateAreaCombo(LocationLiteVo value)
{
    form.cmbArea().clear();
    if (form.cmbEmergencyDep().getValue()==null)
        return;

    TrackingAreaVoCollection collAreas = domain.getTrackingAreasByLocation(form.cmbEmergencyDep().getValue());
    if (collAreas == null)
        return;

    for (int i = 0; i < collAreas.size(); i++)
    {
        form.cmbArea().newRow(collAreas.get(i), collAreas.get(i).getAreaDisplayName());
    }
    form.cmbArea().showOpened();
}
项目:openMAXIMS    文件:Logic.java   
private void populateGridToArea()
{
    //TrackingAreaVoCollection collAreas = domain.getAreasDefinitions(form.cmbFromArea().getValue().getEDLocation());
     TrackingConfigurationVo trackConfig = domain.getTrackingConfig(form.cmbFromArea().getValue().getEDLocation());

    if (trackConfig==null)
        return;

    TrackingAreaVoCollection collAreas = trackConfig.getAreas();

    if (collAreas==null)
        return;

    for (int i=0;i<collAreas.size();i++)
    {
        if (collAreas.get(i).getIsRegistrationArea() || collAreas.get(i).getIsOverallView() || (collAreas.get(i).getStatusIsNotNull() && PreActiveActiveInactiveStatus.INACTIVE.equals(collAreas.get(i).getStatus())))
            continue;

        if (!collAreas.get(i).equals(form.cmbFromArea().getValue()))
        {
            addRow(collAreas.get(i));
        }
    }
}
项目:openMAXIMS    文件:Logic.java   
public TrackingAreaVoCollection getValue()
{
    TrackingAreaVoCollection collectionToSave = new TrackingAreaVoCollection();

    if (form.getLocalContext().getTrackingAreaCollection() == null)
    {
        clear();
        addOverallView();
        addRegistrationArea();// FB
    }

    for (int i = 0; i < form.grdAreaDefinition().getRows().size(); i++)
    {
        collectionToSave.add(form.grdAreaDefinition().getValues().get(i));
    }

    if (form.getLocalContext().getRegistrationArea() != null)
    {
        collectionToSave.add(form.getLocalContext().getRegistrationArea());// FB
    }

    return collectionToSave;

}
项目:openMAXIMS    文件:Logic.java   
private void populateGrid()
{
    form.grdConfig().getRows().clear();

    if (form.getGlobalContext().Emergency.getTrackingArea() == null)
        return;
    else if (form.getGlobalContext().Emergency.getTrackingArea().getSendToAreas() == null)
        return;

    TrackingAreaVoCollection collToArea = form.getGlobalContext().Emergency.getTrackingArea().getSendToAreas();

    for (int i = 0; i < collToArea.size(); i++)
    {
        grdConfigRow row = form.grdConfig().getRows().newRow();
        row.setcolArea(collToArea.get(i).getAreaDisplayName());
        row.setValue(collToArea.get(i));
    }
}
项目:openMAXIMS    文件:Logic.java   
public void initialize(Boolean argument, TrackingAreaVoCollection areaDefCollection)
{
    if (argument && areaDefCollection == null && form.cmbArea().getValue() != null) // Send To Config Menu
    {
        form.getGlobalContext().Emergency.setTrackingArea(domain.getTrackingArea(form.cmbArea().getValue()));
        engine.open(form.getForms().Emergency.SendToConfigDialog);
    }
    else if (areaDefCollection != null) // view Mode
    {
        populateFromAreaCombo(areaDefCollection);
        form.getGlobalContext().Emergency.setTrackingArea(null);
    }
    else if (!argument && areaDefCollection == null) // if TrackingConfiguration does not have any Area Definitions
    {
        form.getGlobalContext().Emergency.setTrackingArea(null);
    }
    open();
}
项目:openMAXIMS    文件:Logic.java   
private void populateAreaCombo(LocationLiteVo value)
{
    form.cmbArea().clear();
    if (form.cmbEmergencyDep().getValue()==null)
        return;

    TrackingAreaVoCollection collAreas = domain.getTrackingAreasByLocation(form.cmbEmergencyDep().getValue());
    if (collAreas == null)
        return;

    for (int i = 0; i < collAreas.size(); i++)
    {
        form.cmbArea().newRow(collAreas.get(i), collAreas.get(i).getAreaDisplayName());
    }
    form.cmbArea().showOpened();
}
项目:openMAXIMS    文件:Logic.java   
private void populateGridToArea()
{
    //TrackingAreaVoCollection collAreas = domain.getAreasDefinitions(form.cmbFromArea().getValue().getEDLocation());
     TrackingConfigurationVo trackConfig = domain.getTrackingConfig(form.cmbFromArea().getValue().getEDLocation());

    if (trackConfig==null)
        return;

    TrackingAreaVoCollection collAreas = trackConfig.getAreas();

    if (collAreas==null)
        return;

    for (int i=0;i<collAreas.size();i++)
    {
        if (collAreas.get(i).getIsRegistrationArea() || collAreas.get(i).getIsOverallView() || (collAreas.get(i).getStatusIsNotNull() && PreActiveActiveInactiveStatus.INACTIVE.equals(collAreas.get(i).getStatus())))
            continue;

        if (!collAreas.get(i).equals(form.cmbFromArea().getValue()))
        {
            addRow(collAreas.get(i));
        }
    }
}
项目:openMAXIMS    文件:Logic.java   
public TrackingAreaVoCollection getValue()
{
    TrackingAreaVoCollection collectionToSave = new TrackingAreaVoCollection();

    if (form.getLocalContext().getTrackingAreaCollection() == null)
    {
        clear();
        addOverallView();
        addRegistrationArea();// FB
    }

    for (int i = 0; i < form.grdAreaDefinition().getRows().size(); i++)
    {
        collectionToSave.add(form.grdAreaDefinition().getValues().get(i));
    }

    if (form.getLocalContext().getRegistrationArea() != null)
    {
        collectionToSave.add(form.getLocalContext().getRegistrationArea());// FB
    }

    return collectionToSave;

}
项目:openMAXIMS    文件:Logic.java   
private void ListAwaitingClinicalImagingResult(ILocation currentLocation,TrackingAreaVoCollection areas)
{
    DynamicGridRow row = form.dyngrdAreas().getRows().newRow();
    DynamicGridCell cell = row.getCells().newCell(form.dyngrdAreas().getColumns().getByIdentifier(COL_STATUS), DynamicCellType.STRING);
    cell.setWidth(200);
    cell.setValue("Awaiting Clinical Imaging Result");
    cell.setBackColor(Color.fromRGB(198, 223, 242));                

    for(int i=0;i< areas.size();i++)
    {           
        cell = row.getCells().newCell(form.dyngrdAreas().getColumns().getByIdentifier(COL_AREA+areas.get(i).getID_TrackingArea()), DynamicCellType.STRING);
        cell.setWidth(150);
        //String val="";
        cell.setValue("-");
        //cell.setBackColor(Color.LightSteelBlue);          
    }

    cell = row.getCells().newCell(form.dyngrdAreas().getColumns().getByIdentifier(COL_OVERALL), DynamicCellType.HTMLVIEW);
    cell.setWidth(90);
    cell.setValue("<b>-</B>");
    cell.setBackColor(Color.Bisque);
}
项目:openMAXIMS    文件:Logic.java   
private void ListAwaitingPathologyResult(ILocation currentLocation,TrackingAreaVoCollection areas)
{
    DynamicGridRow row = form.dyngrdAreas().getRows().newRow();
    DynamicGridCell cell = row.getCells().newCell(form.dyngrdAreas().getColumns().getByIdentifier(COL_STATUS), DynamicCellType.STRING);
    cell.setWidth(150);
    cell.setValue("Awaiting Pathology Result");
    cell.setBackColor(Color.fromRGB(198, 223, 242));

    for(int i=0;i< areas.size();i++)
    {           
        cell = row.getCells().newCell(form.dyngrdAreas().getColumns().getByIdentifier(COL_AREA+areas.get(i).getID_TrackingArea()), DynamicCellType.STRING);
        cell.setWidth(150);
        //String val="";
        cell.setValue("-");
        //cell.setBackColor(Color.LightSteelBlue);          
    }

    cell = row.getCells().newCell(form.dyngrdAreas().getColumns().getByIdentifier(COL_OVERALL), DynamicCellType.HTMLVIEW);
    cell.setWidth(90);
    cell.setValue("<b>-</B>");
    cell.setBackColor(Color.Bisque);
}
项目:openMAXIMS    文件:Logic.java   
private void populateAreasRows(TrackingAreaVoCollection areas, ILocation currentLocation) {
    // TODO Auto-generated method stub

    ListAwaitingTriageCounts(areas,currentLocation);
    ListPrioritiesCounts(currentLocation,areas, "Priority 1", ims.emergency.vo.lookups.TriagePriority.PRIORITY1);
    ListPrioritiesCounts(currentLocation,areas, "Priority 2",ims.emergency.vo.lookups.TriagePriority.PRIORITY2);
    ListPrioritiesCounts(currentLocation,areas, "Priority 3",ims.emergency.vo.lookups.TriagePriority.PRIORITY3);
    ListPrioritiesCounts(currentLocation,areas, "Priority 4",ims.emergency.vo.lookups.TriagePriority.PRIORITY4);    
    ListPrioritiesCounts(currentLocation,areas, "Priority 5",ims.emergency.vo.lookups.TriagePriority.PRIORITY5);
    ListUnallocated(currentLocation,areas);
    ListAllocated(currentLocation,areas);
    ListReferredToSpecialty(currentLocation,areas);
    ListAwaitingClinicalImagingResult(currentLocation,areas);
    ListAwaitingPathologyResult(currentLocation,areas);
    List15MinLOSBreached(currentLocation,areas);
    ListLOSBreached(currentLocation,areas);
    ListAverageLengthOfStay(currentLocation,areas);
    ListTotalPatientsOnArea(currentLocation,areas);

}
项目:openMAXIMS    文件:Logic.java   
private void populateGrid()
{
    form.grdConfig().getRows().clear();

    if (form.getGlobalContext().Emergency.getTrackingArea() == null)
        return;
    else if (form.getGlobalContext().Emergency.getTrackingArea().getSendToAreas() == null)
        return;

    TrackingAreaVoCollection collToArea = form.getGlobalContext().Emergency.getTrackingArea().getSendToAreas();

    for (int i = 0; i < collToArea.size(); i++)
    {
        grdConfigRow row = form.grdConfig().getRows().newRow();
        row.setcolArea(collToArea.get(i).getAreaDisplayName());
        row.setValue(collToArea.get(i));
    }
}
项目:openMAXIMS    文件:Logic.java   
public void initialize(Boolean argument, TrackingAreaVoCollection areaDefCollection)
{
    if (argument && areaDefCollection == null && form.cmbArea().getValue() != null) // Send To Config Menu
    {
        form.getGlobalContext().Emergency.setTrackingArea(domain.getTrackingArea(form.cmbArea().getValue()));
        engine.open(form.getForms().Emergency.SendToConfigDialog);
    }
    else if (areaDefCollection != null) // view Mode
    {
        populateFromAreaCombo(areaDefCollection);
        form.getGlobalContext().Emergency.setTrackingArea(null);
    }
    else if (!argument && areaDefCollection == null) // if TrackingConfiguration does not have any Area Definitions
    {
        form.getGlobalContext().Emergency.setTrackingArea(null);
    }
    open();
}
项目:openMAXIMS    文件:EDWorkloadSummaryImpl.java   
public TrackingAreaVoCollection getAreas(ILocation location) 
{
    if (location == null )
    {
        throw new CodingRuntimeException("Cannot get Location on null Id ");
    }

    DomainFactory factory = getDomainFactory();

    StringBuffer hql = new StringBuffer();

    hql.append("select  t2_1 ");
    hql.append(" from TrackingConfiguration as t1_1 left join t1_1.eDLocation as l1_1 left join t1_1.areas as t2_1 left join t2_1.status as l2_1");
    hql.append(" where ");
    hql.append("(l1_1.id = :Location_id and t1_1.isActive = 1 and l2_1.id = :lookup_inst and  (t2_1.isOverallView = 0 or t2_1.isOverallView is null ))");

    List<?> list = factory.find(hql.toString(), new String[] {"Location_id","lookup_inst"}, new Object[] {location.getID(),ims.core.vo.lookups.PreActiveActiveInactiveStatus.ACTIVE.getID()});

    return TrackingAreaVoAssembler.createTrackingAreaVoCollectionFromTrackingArea(list);
}
项目:openmaxims-linux    文件:Logic.java   
private void populateAreaCombo(LocationLiteVo value)
{
    form.cmbArea().clear();
    if (form.cmbEmergencyDep().getValue()==null)
        return;

    TrackingAreaVoCollection collAreas = domain.getTrackingAreasByLocation(form.cmbEmergencyDep().getValue());
    if (collAreas == null)
        return;

    for (int i = 0; i < collAreas.size(); i++)
    {
        form.cmbArea().newRow(collAreas.get(i), collAreas.get(i).getAreaDisplayName());
    }
    form.cmbArea().showOpened();
}
项目:openmaxims-linux    文件:Logic.java   
private void populateGridToArea()
{
    //TrackingAreaVoCollection collAreas = domain.getAreasDefinitions(form.cmbFromArea().getValue().getEDLocation());
     TrackingConfigurationVo trackConfig = domain.getTrackingConfig(form.cmbFromArea().getValue().getEDLocation());

    if (trackConfig==null)
        return;

    TrackingAreaVoCollection collAreas = trackConfig.getAreas();

    if (collAreas==null)
        return;

    for (int i=0;i<collAreas.size();i++)
    {
        if (collAreas.get(i).getIsRegistrationArea() || collAreas.get(i).getIsOverallView() || (collAreas.get(i).getStatusIsNotNull() && PreActiveActiveInactiveStatus.INACTIVE.equals(collAreas.get(i).getStatus())))
            continue;

        if (!collAreas.get(i).equals(form.cmbFromArea().getValue()))
        {
            addRow(collAreas.get(i));
        }
    }
}
项目:openmaxims-linux    文件:Logic.java   
public TrackingAreaVoCollection getValue()
{
    TrackingAreaVoCollection collectionToSave = new TrackingAreaVoCollection();

    if (form.getLocalContext().getTrackingAreaCollection() == null)
    {
        clear();
        addOverallView();
        addRegistrationArea();// FB
    }

    for (int i = 0; i < form.grdAreaDefinition().getRows().size(); i++)
    {
        collectionToSave.add(form.grdAreaDefinition().getValues().get(i));
    }

    if (form.getLocalContext().getRegistrationArea() != null)
    {
        collectionToSave.add(form.getLocalContext().getRegistrationArea());// FB
    }

    return collectionToSave;

}
项目:openmaxims-linux    文件:Logic.java   
private void ListAwaitingClinicalImagingResult(ILocation currentLocation,TrackingAreaVoCollection areas)
{
    DynamicGridRow row = form.dyngrdAreas().getRows().newRow();
    DynamicGridCell cell = row.getCells().newCell(form.dyngrdAreas().getColumns().getByIdentifier(COL_STATUS), DynamicCellType.STRING);
    cell.setWidth(200);
    cell.setValue("Awaiting Clinical Imaging Result");
    cell.setBackColor(Color.fromRGB(198, 223, 242));                

    for(int i=0;i< areas.size();i++)
    {           
        cell = row.getCells().newCell(form.dyngrdAreas().getColumns().getByIdentifier(COL_AREA+areas.get(i).getID_TrackingArea()), DynamicCellType.STRING);
        cell.setWidth(150);
        //String val="";
        cell.setValue("-");
        //cell.setBackColor(Color.LightSteelBlue);          
    }

    cell = row.getCells().newCell(form.dyngrdAreas().getColumns().getByIdentifier(COL_OVERALL), DynamicCellType.HTMLVIEW);
    cell.setWidth(90);
    cell.setValue("<b>-</B>");
    cell.setBackColor(Color.Bisque);
}
项目:openmaxims-linux    文件:Logic.java   
private void ListAwaitingPathologyResult(ILocation currentLocation,TrackingAreaVoCollection areas)
{
    DynamicGridRow row = form.dyngrdAreas().getRows().newRow();
    DynamicGridCell cell = row.getCells().newCell(form.dyngrdAreas().getColumns().getByIdentifier(COL_STATUS), DynamicCellType.STRING);
    cell.setWidth(150);
    cell.setValue("Awaiting Pathology Result");
    cell.setBackColor(Color.fromRGB(198, 223, 242));

    for(int i=0;i< areas.size();i++)
    {           
        cell = row.getCells().newCell(form.dyngrdAreas().getColumns().getByIdentifier(COL_AREA+areas.get(i).getID_TrackingArea()), DynamicCellType.STRING);
        cell.setWidth(150);
        //String val="";
        cell.setValue("-");
        //cell.setBackColor(Color.LightSteelBlue);          
    }

    cell = row.getCells().newCell(form.dyngrdAreas().getColumns().getByIdentifier(COL_OVERALL), DynamicCellType.HTMLVIEW);
    cell.setWidth(90);
    cell.setValue("<b>-</B>");
    cell.setBackColor(Color.Bisque);
}
项目:openmaxims-linux    文件:Logic.java   
private void populateAreasRows(TrackingAreaVoCollection areas, ILocation currentLocation) {
    // TODO Auto-generated method stub

    ListAwaitingTriageCounts(areas,currentLocation);
    ListPrioritiesCounts(currentLocation,areas, "Priority 1", ims.emergency.vo.lookups.TriagePriority.PRIORITY1);
    ListPrioritiesCounts(currentLocation,areas, "Priority 2",ims.emergency.vo.lookups.TriagePriority.PRIORITY2);
    ListPrioritiesCounts(currentLocation,areas, "Priority 3",ims.emergency.vo.lookups.TriagePriority.PRIORITY3);
    ListPrioritiesCounts(currentLocation,areas, "Priority 4",ims.emergency.vo.lookups.TriagePriority.PRIORITY4);    
    ListPrioritiesCounts(currentLocation,areas, "Priority 5",ims.emergency.vo.lookups.TriagePriority.PRIORITY5);
    ListUnallocated(currentLocation,areas);
    ListAllocated(currentLocation,areas);
    ListReferredToSpecialty(currentLocation,areas);
    ListAwaitingClinicalImagingResult(currentLocation,areas);
    ListAwaitingPathologyResult(currentLocation,areas);
    List15MinLOSBreached(currentLocation,areas);
    ListLOSBreached(currentLocation,areas);
    ListAverageLengthOfStay(currentLocation,areas);
    ListTotalPatientsOnArea(currentLocation,areas);

}
项目:openmaxims-linux    文件:Logic.java   
private void populateGrid()
{
    form.grdConfig().getRows().clear();

    if (form.getGlobalContext().Emergency.getTrackingArea() == null)
        return;
    else if (form.getGlobalContext().Emergency.getTrackingArea().getSendToAreas() == null)
        return;

    TrackingAreaVoCollection collToArea = form.getGlobalContext().Emergency.getTrackingArea().getSendToAreas();

    for (int i = 0; i < collToArea.size(); i++)
    {
        grdConfigRow row = form.grdConfig().getRows().newRow();
        row.setcolArea(collToArea.get(i).getAreaDisplayName());
        row.setValue(collToArea.get(i));
    }
}
项目:openmaxims-linux    文件:Logic.java   
public void initialize(Boolean argument, TrackingAreaVoCollection areaDefCollection)
{
    if (argument && areaDefCollection == null && form.cmbArea().getValue() != null) // Send To Config Menu
    {
        form.getGlobalContext().Emergency.setTrackingArea(domain.getTrackingArea(form.cmbArea().getValue()));
        engine.open(form.getForms().Emergency.SendToConfigDialog);
    }
    else if (areaDefCollection != null) // view Mode
    {
        populateFromAreaCombo(areaDefCollection);
        form.getGlobalContext().Emergency.setTrackingArea(null);
    }
    else if (!argument && areaDefCollection == null) // if TrackingConfiguration does not have any Area Definitions
    {
        form.getGlobalContext().Emergency.setTrackingArea(null);
    }
    open();
}
项目:openmaxims-linux    文件:EDWorkloadSummaryImpl.java   
public TrackingAreaVoCollection getAreas(ILocation location) 
{
    if (location == null )
    {
        throw new CodingRuntimeException("Cannot get Location on null Id ");
    }

    DomainFactory factory = getDomainFactory();

    StringBuffer hql = new StringBuffer();

    hql.append("select  t2_1 ");
    hql.append(" from TrackingConfiguration as t1_1 left join t1_1.eDLocation as l1_1 left join t1_1.areas as t2_1 left join t2_1.status as l2_1");
    hql.append(" where ");
    hql.append("(l1_1.id = :Location_id and t1_1.isActive = 1 and l2_1.id = :lookup_inst and  (t2_1.isOverallView = 0 or t2_1.isOverallView is null ))");

    List<?> list = factory.find(hql.toString(), new String[] {"Location_id","lookup_inst"}, new Object[] {location.getID(),ims.core.vo.lookups.PreActiveActiveInactiveStatus.ACTIVE.getID()});

    return TrackingAreaVoAssembler.createTrackingAreaVoCollectionFromTrackingArea(list);
}
项目:AvoinApotti    文件:Logic.java   
public void initialize(Boolean argument, TrackingAreaVoCollection areaDefCollection)
{
    if (argument && areaDefCollection == null && form.cmbArea().getValue() != null) // Edit
    {
        form.getGlobalContext().Emergency.setTrackingAreaWorkspace(domain.getTrackingArea(form.cmbArea().getValue()));
        engine.open(form.getForms().Emergency.TrackingAreaColumnConfigurationDialog);
    }
    else if (areaDefCollection != null) // view Mode
    {
        populateFromAreaCombo(areaDefCollection);
        form.getGlobalContext().Emergency.setTrackingAreaWorkspace(null);
    }
    open();
}
项目:AvoinApotti    文件:Logic.java   
private void populateFromAreaCombo(TrackingAreaVoCollection areaDefCollection)
{
    form.cmbArea().clear();
    for (int i = 0; i < areaDefCollection.size(); i++)
    {
        /*if (areaDefCollection.get(i).getIsOverallView())
            continue;*/

        form.cmbArea().newRow(areaDefCollection.get(i), areaDefCollection.get(i).getAreaDisplayName());
    }
}
项目:AvoinApotti    文件:Logic.java   
private TrackingAreaVo populateTrackingArea(TrackingAreaVo areaToAdd)
{
    TrackingConfigurationVo tracking = form.getLocalContext().getcurrentTrackingConfig();
    TrackingAreaVo areaToSave = new TrackingAreaVo();

    TrackingAreaVoCollection collAreas = tracking.getAreas();
    for (int i = 0; i < collAreas.size(); i++)
    {
        if (collAreas.get(i).getIsOverallView() && areaToAdd.getIsOverallView())
        {
            areaToSave = collAreas.get(i);
            break;
        }
        else if (collAreas.get(i).getIsRegistrationArea() && areaToAdd.getIsRegistrationArea())
        {
            areaToSave = collAreas.get(i);
            break;
        }
    }

    ColumnDetailVoCollection collColumnsToAdd = areaToAdd.getColumns();

    for (int i = 0; i < collColumnsToAdd.size(); i++)
    {
        collColumnsToAdd.get(i).setID_ColumnDetail(null);
        areaToSave.getColumns().add(collColumnsToAdd.get(i));
    }

    return areaToSave;
}
项目:AvoinApotti    文件:Logic.java   
@Override
protected void onCmbAreaValueChanged() throws PresentationLogicException
{

    if (form.cmbArea().getValue()!=null && form.cmbArea().getValue().getColumns()!=null && form.cmbArea().getValue().getColumns().size() == 0)
    {
        engine.showMessage("The Area selected doesn't have Columns configured. Please select another area");
        form.cmbArea().setValue(null);
    }
    else if (form.cmbArea().getValue()!=null && (form.cmbArea().getValue().getIsRegistrationArea() || form.cmbArea().getValue().getIsOverallView()) && form.getLocalContext().getdialogOpenArgument() == null)
    {
        TrackingAreaVoCollection collAreas = form.getLocalContext().getcurrentTrackingConfig().getAreas();
        for (int i = 0; i < collAreas.size(); i++)
        {
            if (form.cmbArea().getValue().getIsRegistrationArea() && collAreas.get(i).getIsRegistrationArea() && collAreas.get(i).getColumns().size() > 0)
            {
                engine.showMessage("There are Columns configured for the Registration Area from the current TrackingConfiguration.\nThe copy is not allowed in this case. \n Please Select another area. ");
                form.cmbArea().setValue(null);
                break;
            }
            else if (form.cmbArea().getValue().getIsOverallView() && collAreas.get(i).getIsOverallView() && collAreas.get(i).getColumns().size() > 0)
            {
                engine.showMessage("There are Columns configured for the Overall Area from the current TrackingConfiguration.\nThe copy is not allowed in this case. \n Please Select another area. ");
                form.cmbArea().setValue(null);
                break;
            }
        }
    }
    updateControlsState();

}
项目:AvoinApotti    文件:Logic.java   
private boolean isSendToArea(TrackingAreaVo trackArea)
{
    TrackingAreaVoCollection sendToAreas = form.cmbFromArea().getValue().getSendToAreas();
    for (int i=0;i<sendToAreas.size();i++)
    {
        if (sendToAreas.get(i).equals(trackArea))
            return true;
    }
    return false;
}
项目:AvoinApotti    文件:Logic.java   
private void populateDataFromScreen()
{
    TrackingAreaVoCollection collSendToArea = new TrackingAreaVoCollection();
    grdToAreaRowCollection rows = form.grdToArea().getRows();
    for (int i=0;i<rows.size();i++)
    {
        if (rows.get(i).getcolSelect())
        {
            collSendToArea.add(rows.get(i).getValue());
        }
    }

    form.getGlobalContext().Emergency.getTrackingArea().setSendToAreas(collSendToArea);
}
项目:AvoinApotti    文件:Logic.java   
private void populateScreenFromData()
{
    TrackingAreaVoCollection trackingAreaCollection;

    clear();
    form.getLocalContext().setRegistrationArea(null); // FB

    if (form.getLocalContext().getTrackingAreaCollectionIsNotNull())
    {
        trackingAreaCollection = form.getLocalContext().getTrackingAreaCollection();

        for (int i = 0; i < trackingAreaCollection.size(); i++)
        {
            grdAreaDefinitionRow row = form.grdAreaDefinition().getRows().newRow();
            row.setArea(trackingAreaCollection.get(i).getAreaDisplayName());
            //row.setPatRefreshRate(trackingAreaCollection.get(i).getPatientRefreshRate().toString());
            row.setStatus(trackingAreaCollection.get(i).getStatus().toString());
            row.setValue(trackingAreaCollection.get(i));

            if (trackingAreaCollection.get(i).getIsOverallViewIsNotNull() && trackingAreaCollection.get(i).getIsOverallView())
            {
                row.setBackColor(Color.Beige);
            }

            if (trackingAreaCollection.get(i).getIsRegistrationAreaIsNotNull() && trackingAreaCollection.get(i).getIsRegistrationArea())
            {
                row.setBackColor(Color.Beige);
                form.getLocalContext().setRegistrationArea(trackingAreaCollection.get(i));
            }
        }
    }
    updateControlsState();
}
项目:AvoinApotti    文件:Logic.java   
private void populateSendToAreaGrid(TrackingAreaVoCollection tempCollVo)
{
    //form.grdSendToArea().setEnabled(true);
    form.grdSendToArea().getRows().clear();

    if(tempCollVo == null)
        return;

    for(int i = 0; i < tempCollVo.size(); i++)
    {
        TrackingAreaVo tempVo = tempCollVo.get(i);

        //WDEV-15815 //WDEV-17249
        if(tempVo != null && ((tempVo.getAreaType() == null) || form.getGlobalContext().Core.getPatientShort() == null || (form.getGlobalContext().Core.getPatientShort() != null && form.getGlobalContext().Core.getPatientShort().calculateAge() == null) || ( tempVo.getAreaTypeIsNotNull() && (isAdultPatient() && tempVo.getAreaType().equals(ims.emergency.vo.lookups.AreaType.ADULT_ONLY)) || 
                                                                                                    ( ( ! isAdultPatient()) && tempVo.getAreaType().equals(ims.emergency.vo.lookups.AreaType.PAEDIATRIC_ONLY)))))
        {
            grdSendToAreaRow row = form.grdSendToArea().getRows().newRow();
            row.setColumnArea(tempVo.getAreaDisplayName());

            if (tempCollVo.size() == 1) //WDEV-16557
            {
                row.setColumnSelect(Boolean.TRUE);
            }
            else
                row.setColumnSelect(Boolean.FALSE);

            row.setValue(tempVo);
        }
    }
}