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

项目:AvoinApotti    文件:Logic.java   
private boolean save() 
{
    LocationDepartmentTypesVo locationDepartmentType = populateDataFromScreen(form.getLocalContext().getSelectedInstance());

    String[] errors = locationDepartmentType.validate();
    if(errors != null && errors.length > 0)
    {
        engine.showErrors(errors);
        return false;
    }

    try 
    {
        form.getLocalContext().setSelectedInstance(domain.save(locationDepartmentType));
    } 
    catch (StaleObjectException e) 
    {
        e.printStackTrace();
        engine.showMessage(ConfigFlag.UI.STALE_OBJECT_MESSAGE.getValue());
        open();
        return false;
    }

    return true;
}
项目:AvoinApotti    文件:EmergencyAttendanceDetailsCcImpl.java   
public LocationDepartmentTypesVo getLocationDepartmentTypes(LocationRefVo edLocation)
{
    if(edLocation == null || edLocation.getID_Location() == null)
        return null;

    DomainFactory factory = getDomainFactory();
    String query = "from LocationDepartmentTypes as ldt where ldt.eDLocation.id = :EmergencyLocation";
    List<?> departments = factory.find(query, new String[] {"EmergencyLocation"}, new Object[] {edLocation.getID_Location()});

    if(departments != null && departments.size() > 0)
    {
         return LocationDepartmentTypesVoAssembler.create((LocationDepartmentTypes) departments.get(0));
    }

    return null;
}
项目:AvoinApotti    文件:AttendanceDetailsImpl.java   
public LocationDepartmentTypesVo getLocationDepartmentTypes(LocationRefVo edLocation)
{
    if(edLocation == null || edLocation.getID_Location() == null)
        return null;

    DomainFactory factory = getDomainFactory();
    String query = "from LocationDepartmentTypes as ldt where ldt.eDLocation.id = :EmergencyLocation";
    List<?> departments = factory.find(query, new String[] {"EmergencyLocation"}, new Object[] {edLocation.getID_Location()});

    if(departments != null && departments.size() > 0)
    {
         return LocationDepartmentTypesVoAssembler.create((LocationDepartmentTypes) departments.get(0));
    }

    return null;
}
项目:AvoinApotti    文件:DepartmentTypeConfigImpl.java   
public ims.emergency.vo.LocationDepartmentTypesVo save(ims.emergency.vo.LocationDepartmentTypesVo locationDepartmentTypes) throws ims.domain.exceptions.StaleObjectException
{
    if(locationDepartmentTypes == null)
        throw new CodingRuntimeException("Cannnot save a null LocationDepartmentType.");

    if(!locationDepartmentTypes.isValidated())
        throw new CodingRuntimeException("LocationDepartmentType is not validated.");

    DomainFactory factory = getDomainFactory();
    LocationDepartmentTypes doLocationDepartmentType = LocationDepartmentTypesVoAssembler.extractLocationDepartmentTypes(factory, locationDepartmentTypes);

    if(locationDepartmentTypes.getID_LocationDepartmentTypes() == null)
    {
        LocationDepartmentTypesVo locationDepartmentTypesFromDB = get(locationDepartmentTypes.getEDLocation());

        if(locationDepartmentTypesFromDB != null && locationDepartmentTypesFromDB.getID_LocationDepartmentTypes() != null)
            throw new StaleObjectException(doLocationDepartmentType);
    }

    factory.save(doLocationDepartmentType);

    return LocationDepartmentTypesVoAssembler.create(doLocationDepartmentType);
}
项目:openMAXIMS    文件:Logic.java   
private boolean save() 
{
    LocationDepartmentTypesVo locationDepartmentType = populateDataFromScreen(form.getLocalContext().getSelectedInstance());

    String[] errors = locationDepartmentType.validate();
    if(errors != null && errors.length > 0)
    {
        engine.showErrors(errors);
        return false;
    }

    try 
    {
        form.getLocalContext().setSelectedInstance(domain.save(locationDepartmentType));
    } 
    catch (StaleObjectException e) 
    {
        e.printStackTrace();
        engine.showMessage(ConfigFlag.UI.STALE_OBJECT_MESSAGE.getValue());
        open();
        return false;
    }

    return true;
}
项目:openMAXIMS    文件:EmergencyAttendanceDetailsCcImpl.java   
public LocationDepartmentTypesVo getLocationDepartmentTypes(LocationRefVo edLocation)
{
    if(edLocation == null || edLocation.getID_Location() == null)
        return null;

    DomainFactory factory = getDomainFactory();
    String query = "from LocationDepartmentTypes as ldt where ldt.eDLocation.id = :EmergencyLocation";
    List<?> departments = factory.find(query, new String[] {"EmergencyLocation"}, new Object[] {edLocation.getID_Location()});

    if(departments != null && departments.size() > 0)
    {
         return LocationDepartmentTypesVoAssembler.create((LocationDepartmentTypes) departments.get(0));
    }

    return null;
}
项目:openMAXIMS    文件:AttendanceDetailsImpl.java   
public LocationDepartmentTypesVo getLocationDepartmentTypes(LocationRefVo edLocation)
{
    if(edLocation == null || edLocation.getID_Location() == null)
        return null;

    DomainFactory factory = getDomainFactory();
    String query = "from LocationDepartmentTypes as ldt where ldt.eDLocation.id = :EmergencyLocation";
    List<?> departments = factory.find(query, new String[] {"EmergencyLocation"}, new Object[] {edLocation.getID_Location()});

    if(departments != null && departments.size() > 0)
    {
         return LocationDepartmentTypesVoAssembler.create((LocationDepartmentTypes) departments.get(0));
    }

    return null;
}
项目:openMAXIMS    文件:DepartmentTypeConfigImpl.java   
public ims.emergency.vo.LocationDepartmentTypesVo save(ims.emergency.vo.LocationDepartmentTypesVo locationDepartmentTypes) throws ims.domain.exceptions.StaleObjectException
{
    if(locationDepartmentTypes == null)
        throw new CodingRuntimeException("Cannnot save a null LocationDepartmentType.");

    if(!locationDepartmentTypes.isValidated())
        throw new CodingRuntimeException("LocationDepartmentType is not validated.");

    DomainFactory factory = getDomainFactory();
    LocationDepartmentTypes doLocationDepartmentType = LocationDepartmentTypesVoAssembler.extractLocationDepartmentTypes(factory, locationDepartmentTypes);

    if(locationDepartmentTypes.getID_LocationDepartmentTypes() == null)
    {
        LocationDepartmentTypesVo locationDepartmentTypesFromDB = get(locationDepartmentTypes.getEDLocation());

        if(locationDepartmentTypesFromDB != null && locationDepartmentTypesFromDB.getID_LocationDepartmentTypes() != null)
            throw new StaleObjectException(doLocationDepartmentType);
    }

    factory.save(doLocationDepartmentType);

    return LocationDepartmentTypesVoAssembler.create(doLocationDepartmentType);
}
项目:openMAXIMS    文件:Logic.java   
private boolean save() 
{
    LocationDepartmentTypesVo locationDepartmentType = populateDataFromScreen(form.getLocalContext().getSelectedInstance());

    String[] errors = locationDepartmentType.validate();
    if(errors != null && errors.length > 0)
    {
        engine.showErrors(errors);
        return false;
    }

    try 
    {
        form.getLocalContext().setSelectedInstance(domain.save(locationDepartmentType));
    } 
    catch (StaleObjectException e) 
    {
        e.printStackTrace();
        engine.showMessage(ConfigFlag.UI.STALE_OBJECT_MESSAGE.getValue());
        open();
        return false;
    }

    return true;
}
项目:openMAXIMS    文件:EmergencyAttendanceDetailsCcImpl.java   
public LocationDepartmentTypesVo getLocationDepartmentTypes(LocationRefVo edLocation)
{
    if(edLocation == null || edLocation.getID_Location() == null)
        return null;

    DomainFactory factory = getDomainFactory();
    String query = "from LocationDepartmentTypes as ldt where ldt.eDLocation.id = :EmergencyLocation";
    List<?> departments = factory.find(query, new String[] {"EmergencyLocation"}, new Object[] {edLocation.getID_Location()});

    if(departments != null && departments.size() > 0)
    {
         return LocationDepartmentTypesVoAssembler.create((LocationDepartmentTypes) departments.get(0));
    }

    return null;
}
项目:openMAXIMS    文件:AttendanceDetailsImpl.java   
public LocationDepartmentTypesVo getLocationDepartmentTypes(LocationRefVo edLocation)
{
    if(edLocation == null || edLocation.getID_Location() == null)
        return null;

    DomainFactory factory = getDomainFactory();
    String query = "from LocationDepartmentTypes as ldt where ldt.eDLocation.id = :EmergencyLocation";
    List<?> departments = factory.find(query, new String[] {"EmergencyLocation"}, new Object[] {edLocation.getID_Location()});

    if(departments != null && departments.size() > 0)
    {
         return LocationDepartmentTypesVoAssembler.create((LocationDepartmentTypes) departments.get(0));
    }

    return null;
}
项目:openMAXIMS    文件:DepartmentTypeConfigImpl.java   
public ims.emergency.vo.LocationDepartmentTypesVo save(ims.emergency.vo.LocationDepartmentTypesVo locationDepartmentTypes) throws ims.domain.exceptions.StaleObjectException
{
    if(locationDepartmentTypes == null)
        throw new CodingRuntimeException("Cannnot save a null LocationDepartmentType.");

    if(!locationDepartmentTypes.isValidated())
        throw new CodingRuntimeException("LocationDepartmentType is not validated.");

    DomainFactory factory = getDomainFactory();
    LocationDepartmentTypes doLocationDepartmentType = LocationDepartmentTypesVoAssembler.extractLocationDepartmentTypes(factory, locationDepartmentTypes);

    if(locationDepartmentTypes.getID_LocationDepartmentTypes() == null)
    {
        LocationDepartmentTypesVo locationDepartmentTypesFromDB = get(locationDepartmentTypes.getEDLocation());

        if(locationDepartmentTypesFromDB != null && locationDepartmentTypesFromDB.getID_LocationDepartmentTypes() != null)
            throw new StaleObjectException(doLocationDepartmentType);
    }

    factory.save(doLocationDepartmentType);

    return LocationDepartmentTypesVoAssembler.create(doLocationDepartmentType);
}
项目:openmaxims-linux    文件:Logic.java   
private boolean save() 
{
    LocationDepartmentTypesVo locationDepartmentType = populateDataFromScreen(form.getLocalContext().getSelectedInstance());

    String[] errors = locationDepartmentType.validate();
    if(errors != null && errors.length > 0)
    {
        engine.showErrors(errors);
        return false;
    }

    try 
    {
        form.getLocalContext().setSelectedInstance(domain.save(locationDepartmentType));
    } 
    catch (StaleObjectException e) 
    {
        e.printStackTrace();
        engine.showMessage(ConfigFlag.UI.STALE_OBJECT_MESSAGE.getValue());
        open();
        return false;
    }

    return true;
}
项目:openmaxims-linux    文件:EmergencyAttendanceDetailsCcImpl.java   
public LocationDepartmentTypesVo getLocationDepartmentTypes(LocationRefVo edLocation)
{
    if(edLocation == null || edLocation.getID_Location() == null)
        return null;

    DomainFactory factory = getDomainFactory();
    String query = "from LocationDepartmentTypes as ldt where ldt.eDLocation.id = :EmergencyLocation";
    List<?> departments = factory.find(query, new String[] {"EmergencyLocation"}, new Object[] {edLocation.getID_Location()});

    if(departments != null && departments.size() > 0)
    {
         return LocationDepartmentTypesVoAssembler.create((LocationDepartmentTypes) departments.get(0));
    }

    return null;
}
项目:openmaxims-linux    文件:AttendanceDetailsImpl.java   
public LocationDepartmentTypesVo getLocationDepartmentTypes(LocationRefVo edLocation)
{
    if(edLocation == null || edLocation.getID_Location() == null)
        return null;

    DomainFactory factory = getDomainFactory();
    String query = "from LocationDepartmentTypes as ldt where ldt.eDLocation.id = :EmergencyLocation";
    List<?> departments = factory.find(query, new String[] {"EmergencyLocation"}, new Object[] {edLocation.getID_Location()});

    if(departments != null && departments.size() > 0)
    {
         return LocationDepartmentTypesVoAssembler.create((LocationDepartmentTypes) departments.get(0));
    }

    return null;
}
项目:openmaxims-linux    文件:DepartmentTypeConfigImpl.java   
public ims.emergency.vo.LocationDepartmentTypesVo save(ims.emergency.vo.LocationDepartmentTypesVo locationDepartmentTypes) throws ims.domain.exceptions.StaleObjectException
{
    if(locationDepartmentTypes == null)
        throw new CodingRuntimeException("Cannnot save a null LocationDepartmentType.");

    if(!locationDepartmentTypes.isValidated())
        throw new CodingRuntimeException("LocationDepartmentType is not validated.");

    DomainFactory factory = getDomainFactory();
    LocationDepartmentTypes doLocationDepartmentType = LocationDepartmentTypesVoAssembler.extractLocationDepartmentTypes(factory, locationDepartmentTypes);

    if(locationDepartmentTypes.getID_LocationDepartmentTypes() == null)
    {
        LocationDepartmentTypesVo locationDepartmentTypesFromDB = get(locationDepartmentTypes.getEDLocation());

        if(locationDepartmentTypesFromDB != null && locationDepartmentTypesFromDB.getID_LocationDepartmentTypes() != null)
            throw new StaleObjectException(doLocationDepartmentType);
    }

    factory.save(doLocationDepartmentType);

    return LocationDepartmentTypesVoAssembler.create(doLocationDepartmentType);
}
项目:AvoinApotti    文件:Logic.java   
private void newInstance() 
{   
    form.setMode(FormMode.EDIT);

    LocationDepartmentTypesVo locationDepartmentType = new LocationDepartmentTypesVo();
    locationDepartmentType.setEDLocation(form.cmbEDLocation().getValue());

    populateScreenFromData(locationDepartmentType);
}
项目:AvoinApotti    文件:DepartmentTypeConfigImpl.java   
public LocationDepartmentTypesVo get(LocationRefVo edLocation) 
{
    if(edLocation == null || edLocation.getID_Location() == null)
        return null;

    String query = "from LocationDepartmentTypes as locConfig where locConfig.eDLocation.id = :EDLocationId";
    DomainFactory factory = getDomainFactory();
    List<?> list = factory.find(query, new String[] {"EDLocationId"}, new Object[] {edLocation.getID_Location()});

    if(list != null && list.size() > 0)
        return LocationDepartmentTypesVoAssembler.create((LocationDepartmentTypes) list.get(0));

    return null;
}
项目:openMAXIMS    文件:Logic.java   
private void newInstance() 
{   
    form.setMode(FormMode.EDIT);

    LocationDepartmentTypesVo locationDepartmentType = new LocationDepartmentTypesVo();
    locationDepartmentType.setEDLocation(form.cmbEDLocation().getValue());

    populateScreenFromData(locationDepartmentType);
}
项目:openMAXIMS    文件:DepartmentTypeConfigImpl.java   
public LocationDepartmentTypesVo get(LocationRefVo edLocation) 
{
    if(edLocation == null || edLocation.getID_Location() == null)
        return null;

    String query = "from LocationDepartmentTypes as locConfig where locConfig.eDLocation.id = :EDLocationId";
    DomainFactory factory = getDomainFactory();
    List<?> list = factory.find(query, new String[] {"EDLocationId"}, new Object[] {edLocation.getID_Location()});

    if(list != null && list.size() > 0)
        return LocationDepartmentTypesVoAssembler.create((LocationDepartmentTypes) list.get(0));

    return null;
}
项目:openMAXIMS    文件:Logic.java   
private void newInstance() 
{   
    form.setMode(FormMode.EDIT);

    LocationDepartmentTypesVo locationDepartmentType = new LocationDepartmentTypesVo();
    locationDepartmentType.setEDLocation(form.cmbEDLocation().getValue());

    populateScreenFromData(locationDepartmentType);
}
项目:openMAXIMS    文件:DepartmentTypeConfigImpl.java   
public LocationDepartmentTypesVo get(LocationRefVo edLocation) 
{
    if(edLocation == null || edLocation.getID_Location() == null)
        return null;

    String query = "from LocationDepartmentTypes as locConfig where locConfig.eDLocation.id = :EDLocationId";
    DomainFactory factory = getDomainFactory();
    List<?> list = factory.find(query, new String[] {"EDLocationId"}, new Object[] {edLocation.getID_Location()});

    if(list != null && list.size() > 0)
        return LocationDepartmentTypesVoAssembler.create((LocationDepartmentTypes) list.get(0));

    return null;
}
项目:openmaxims-linux    文件:Logic.java   
private void newInstance() 
{   
    form.setMode(FormMode.EDIT);

    LocationDepartmentTypesVo locationDepartmentType = new LocationDepartmentTypesVo();
    locationDepartmentType.setEDLocation(form.cmbEDLocation().getValue());

    populateScreenFromData(locationDepartmentType);
}
项目:openmaxims-linux    文件:DepartmentTypeConfigImpl.java   
public LocationDepartmentTypesVo get(LocationRefVo edLocation) 
{
    if(edLocation == null || edLocation.getID_Location() == null)
        return null;

    String query = "from LocationDepartmentTypes as locConfig where locConfig.eDLocation.id = :EDLocationId";
    DomainFactory factory = getDomainFactory();
    List<?> list = factory.find(query, new String[] {"EDLocationId"}, new Object[] {edLocation.getID_Location()});

    if(list != null && list.size() > 0)
        return LocationDepartmentTypesVoAssembler.create((LocationDepartmentTypes) list.get(0));

    return null;
}
项目:AvoinApotti    文件:Logic.java   
private void populateScreenFromData(LocationDepartmentTypesVo locationDepartmentTypes) 
{
    populateDepartmentsGrid(locationDepartmentTypes);
}
项目:AvoinApotti    文件:Logic.java   
private void populateDepartmentsGrid(LocationDepartmentTypesVo locationDepartmentTypes) 
{
    form.dyngrdDepartments().getRows().clear();

    if(FormMode.EDIT.equals(form.getMode()))
    {
        populateDepartmentsGridWithDefault();
    }

    if(locationDepartmentTypes == null || locationDepartmentTypes.getDepartmentTypes() == null)
        return;

    for(int i=0; i<locationDepartmentTypes.getDepartmentTypes().size(); i++)
    {
        if(locationDepartmentTypes.getDepartmentTypes().get(i) == null)
            continue;

        DynamicGridRow row = getRowByDepartment(locationDepartmentTypes.getDepartmentTypes().get(i));

        if(row == null)
            row = form.dyngrdDepartments().getRows().newRow();

        DynamicGridCell cell = row.getCells().newCell(getSelectedColumn(COLDEPARTMENT), DynamicCellType.LABEL);
        cell.setValue(locationDepartmentTypes.getDepartmentTypes().get(i).getText());
        cell.setTooltip(locationDepartmentTypes.getDepartmentTypes().get(i).getText());
        cell.setReadOnly(true);

        cell = row.getCells().newCell(getSelectedColumn(COLSELECTED), DynamicCellType.BOOL);
        cell.setAutoPostBack(true);
        cell.setValue(true);

        cell = row.getCells().newCell(getSelectedColumn(COLDEFAULT), DynamicCellType.BOOL);
        cell.setAutoPostBack(true);

        if(locationDepartmentTypes.getDepartmentTypes().get(i).equals(locationDepartmentTypes.getDefaultDepartmentType()))
        {
            cell.setValue(true);
        }

        row.setValue(locationDepartmentTypes.getDepartmentTypes().get(i));
    }
}
项目:openMAXIMS    文件:Logic.java   
private void populateScreenFromData(LocationDepartmentTypesVo locationDepartmentTypes) 
{
    populateDepartmentsGrid(locationDepartmentTypes);
}
项目:openMAXIMS    文件:Logic.java   
private void populateDepartmentsGrid(LocationDepartmentTypesVo locationDepartmentTypes) 
{
    form.dyngrdDepartments().getRows().clear();

    if(FormMode.EDIT.equals(form.getMode()))
    {
        populateDepartmentsGridWithDefault();
    }

    if(locationDepartmentTypes == null || locationDepartmentTypes.getDepartmentTypes() == null)
        return;

    for(int i=0; i<locationDepartmentTypes.getDepartmentTypes().size(); i++)
    {
        if(locationDepartmentTypes.getDepartmentTypes().get(i) == null)
            continue;

        DynamicGridRow row = getRowByDepartment(locationDepartmentTypes.getDepartmentTypes().get(i));

        if(row == null)
            row = form.dyngrdDepartments().getRows().newRow();

        DynamicGridCell cell = row.getCells().newCell(getSelectedColumn(COLDEPARTMENT), DynamicCellType.LABEL);
        cell.setValue(locationDepartmentTypes.getDepartmentTypes().get(i).getText());
        cell.setTooltip(locationDepartmentTypes.getDepartmentTypes().get(i).getText());
        cell.setReadOnly(true);

        cell = row.getCells().newCell(getSelectedColumn(COLSELECTED), DynamicCellType.BOOL);
        cell.setAutoPostBack(true);
        cell.setValue(true);

        cell = row.getCells().newCell(getSelectedColumn(COLDEFAULT), DynamicCellType.BOOL);
        cell.setAutoPostBack(true);

        if(locationDepartmentTypes.getDepartmentTypes().get(i).equals(locationDepartmentTypes.getDefaultDepartmentType()))
        {
            cell.setValue(true);
        }

        row.setValue(locationDepartmentTypes.getDepartmentTypes().get(i));
    }
}
项目:openMAXIMS    文件:Logic.java   
private void populateScreenFromData(LocationDepartmentTypesVo locationDepartmentTypes) 
{
    populateDepartmentsGrid(locationDepartmentTypes);
}
项目:openMAXIMS    文件:Logic.java   
private void populateDepartmentsGrid(LocationDepartmentTypesVo locationDepartmentTypes) 
{
    form.dyngrdDepartments().getRows().clear();

    if(FormMode.EDIT.equals(form.getMode()))
    {
        populateDepartmentsGridWithDefault();
    }

    if(locationDepartmentTypes == null || locationDepartmentTypes.getDepartmentTypes() == null)
        return;

    for(int i=0; i<locationDepartmentTypes.getDepartmentTypes().size(); i++)
    {
        if(locationDepartmentTypes.getDepartmentTypes().get(i) == null)
            continue;

        DynamicGridRow row = getRowByDepartment(locationDepartmentTypes.getDepartmentTypes().get(i));

        if(row == null)
            row = form.dyngrdDepartments().getRows().newRow();

        DynamicGridCell cell = row.getCells().newCell(getSelectedColumn(COLDEPARTMENT), DynamicCellType.LABEL);
        cell.setValue(locationDepartmentTypes.getDepartmentTypes().get(i).getText());
        cell.setTooltip(locationDepartmentTypes.getDepartmentTypes().get(i).getText());
        cell.setReadOnly(true);

        cell = row.getCells().newCell(getSelectedColumn(COLSELECTED), DynamicCellType.BOOL);
        cell.setAutoPostBack(true);
        cell.setValue(true);

        cell = row.getCells().newCell(getSelectedColumn(COLDEFAULT), DynamicCellType.BOOL);
        cell.setAutoPostBack(true);

        if(locationDepartmentTypes.getDepartmentTypes().get(i).equals(locationDepartmentTypes.getDefaultDepartmentType()))
        {
            cell.setValue(true);
        }

        row.setValue(locationDepartmentTypes.getDepartmentTypes().get(i));
    }
}
项目:openmaxims-linux    文件:Logic.java   
private void populateScreenFromData(LocationDepartmentTypesVo locationDepartmentTypes) 
{
    populateDepartmentsGrid(locationDepartmentTypes);
}
项目:openmaxims-linux    文件:Logic.java   
private void populateDepartmentsGrid(LocationDepartmentTypesVo locationDepartmentTypes) 
{
    form.dyngrdDepartments().getRows().clear();

    if(FormMode.EDIT.equals(form.getMode()))
    {
        populateDepartmentsGridWithDefault();
    }

    if(locationDepartmentTypes == null || locationDepartmentTypes.getDepartmentTypes() == null)
        return;

    for(int i=0; i<locationDepartmentTypes.getDepartmentTypes().size(); i++)
    {
        if(locationDepartmentTypes.getDepartmentTypes().get(i) == null)
            continue;

        DynamicGridRow row = getRowByDepartment(locationDepartmentTypes.getDepartmentTypes().get(i));

        if(row == null)
            row = form.dyngrdDepartments().getRows().newRow();

        DynamicGridCell cell = row.getCells().newCell(getSelectedColumn(COLDEPARTMENT), DynamicCellType.LABEL);
        cell.setValue(locationDepartmentTypes.getDepartmentTypes().get(i).getText());
        cell.setTooltip(locationDepartmentTypes.getDepartmentTypes().get(i).getText());
        cell.setReadOnly(true);

        cell = row.getCells().newCell(getSelectedColumn(COLSELECTED), DynamicCellType.BOOL);
        cell.setAutoPostBack(true);
        cell.setValue(true);

        cell = row.getCells().newCell(getSelectedColumn(COLDEFAULT), DynamicCellType.BOOL);
        cell.setAutoPostBack(true);

        if(locationDepartmentTypes.getDepartmentTypes().get(i).equals(locationDepartmentTypes.getDefaultDepartmentType()))
        {
            cell.setValue(true);
        }

        row.setValue(locationDepartmentTypes.getDepartmentTypes().get(i));
    }
}