public void setUserApplicationInfo(UserApplicationInfo userApplicationInfo) { blueprint.setUserApplicationInfo(userApplicationInfo); }
public UserApplicationInfo getUserApplicationInfo() { return blueprint.getUserApplicationInfo(); }
private DeskmanagerApplicationInfoUserData buildDeskmanagerApplicationInfoUserData( UserApplicationInfo userApplicationInfo) { DeskmanagerApplicationInfoUserData clientUserDataInfo = new DeskmanagerApplicationInfoUserData(); clientUserDataInfo.setDeskmanagerBuild(deskmanagerBuild); clientUserDataInfo.setDeskmanagerVersion(deskmanagerVersion); clientUserDataInfo.setUserApplicationKey(userApplicationInfo.getKey()); return clientUserDataInfo; }
private ListGridRecord toGridRecord(GeodeskDto loket) { ListGridRecord record = new ListGridRecord(); record.setAttribute(FLD_ID, loket.getId()); record.setAttribute(FLD_NAME, loket.getName()); record.setAttribute(FLD_BLUEPRINT, loket.getBlueprint().getName()); record.setAttribute(FLD_AUTHOR, loket.getLastEditBy()); record.setAttribute(FLD_PUBLIC, loket.isPublic()); record.setAttribute(FLD_ACTIVE, loket.isActive() && loket.getBlueprint().isGeodesksActive()); record.setAttribute(FLD_ACTIONS, " "); record.setAttribute(FLD_GEODESKID, loket.getGeodeskId()); record.setAttribute(FLD_OWNER, loket.getOwner() != null ? loket.getOwner().getName() : MESSAGES.geodeskGridColumnOwnerNoOwner()); record.setAttribute(FLD_OBJECT, loket); return record; }
private ListGridRecord toGridRecord(BlueprintDto blueprint) { ListGridRecord record = new ListGridRecord(); record.setAttribute(FLD_ID, blueprint.getId()); record.setAttribute(FLD_NAME, blueprint.getName()); record.setAttribute(FLD_LIMIT_TO_TERRITORY, blueprint.isLimitToCreatorTerritory()); record.setAttribute(FLD_PUBLIC, blueprint.isPublic()); record.setAttribute(FLD_ACTIVE, blueprint.isActive()); record.setAttribute(FLD_GEODESKSACTIVE, blueprint.isGeodesksActive()); return record; }
private ListGridRecord toGridRecord(LayerModelDto lm) { ListGridRecord record = new ListGridRecord(); record.setAttribute(FLD_ID, lm.getId()); record.setAttribute(FLD_NAME, lm.getName()); record.setAttribute(FLD_TYPE, lm.getLayerType()); record.setAttribute(FLD_PUBLIC, lm.isPublic()); record.setAttribute(FLD_ACTIVE, lm.isActive()); record.setAttribute(FLD_OWNER, lm.getOwner()); record.setAttribute(FLD_ACTIONS, " "); record.setAttribute(FLD_OBJECT, lm); return record; }
public void execute(GetClientLayersResponse result) { if (geodesk.getMainMapLayers() == null || geodesk.getMainMapLayers().size() == 0) { //If no layers is set, present default from blueprint layerSelect.setValues(geodesk.getBlueprint().getMainMapLayers(), result.getLayers(), geodesk.getBlueprint().getMainMapLayers(), !geodesk.isPublic()); } else { layerSelect.setValues(geodesk.getBlueprint().getMainMapLayers(), result.getLayers(), geodesk.getMainMapLayers(), !geodesk.isPublic()); } fireChangedHandler(); }
public void onChanged(ChangedEvent event) { boolean val = publicGeodesk.getValueAsBoolean(); if (geodesk.getBlueprint().isLimitToCreatorTerritory()) { limitToCreatorTerritory.setDisabled(true); } else { limitToCreatorTerritory.setDisabled(!val); } if (geodesk.getBlueprint().isLimitToUserTerritory()) { limitToUserTerritory.setDisabled(true); } else { limitToUserTerritory.setDisabled(val); } } });
public void setLayerModel(LayerModelDto lmd) { form.clearValues(); this.lmd = lmd; if (lmd != null) { if (lmd.getLayerConfiguration().getClientLayerInfo() == null) { form.setLayerModel(lmd); } else { form.setData(lmd.getLayerConfiguration()); } } fireChangedHandler(); }
public void setLayerModel(LayerModelDto lmd) { form.clearValues(); this.lmd = lmd; if (lmd != null) { form.updateFields(getFieldList(lmd.getParameterValue(DynamicLayerConfiguration.PARAM_SOURCE_TYPE))); form.setData(paramsToString(lmd.getLayerConfiguration().getParameters())); } else { form.updateFields(new ArrayList<FormElement>()); } fireChangedHandler(); }
public boolean onSaveClick(ClickEvent event) { if (validate()) { lmd.getLayerConfiguration().getParameters().clear(); lmd.getLayerConfiguration().getParameters().addAll(stringToParams(form.getData())); ManagerCommandService.saveLayerModel(lmd, SaveLayerModelRequest.SAVE_SETTINGS); form.setDisabled(true); return true; } else { return false; } }
/** * Retrieve the main map layers from the geodesk. If it's a geodesk without layers, the layers from the blueprint * are retrieved. * * @param geodesk the geodesk * @return a list of layers */ public static List<LayerDto> getMainMapLayers(BaseGeodeskDto geodesk) { if (geodesk instanceof GeodeskDto && (geodesk.getMainMapLayers() == null || geodesk.getMainMapLayers().isEmpty())) { return getMainMapLayers(((GeodeskDto) geodesk).getBlueprint()); } return geodesk.getMainMapLayers(); } }
public boolean isDefault() { return geodesk.getMainMapLayers() == null || geodesk.getMainMapLayers().isEmpty(); } }
public void setBlueprint(BlueprintDto blueprint) { this.blueprint = blueprint; if (blueprint != null) { groupSelect.setValues(blueprint.getTerritories()); } else { groupSelect.setValues(null); } fireChangedHandler(); }
public String getParameterValue(String key) { if (key == null || "".equals(key) || layerConfiguration == null) { return null; } else { return layerConfiguration.getParameterValue(key); } }
/** * Retrieve the mapinfo from the geodesk's main map. * * @param geodesk the geodesk * @return the mapInfo */ public static ClientMapInfo getMainMap(BaseGeodeskDto geodesk) { return UserApplicationDtoUtil.getMainMap(geodesk.getUserApplicationInfo()); }
public boolean onSaveClick(ClickEvent event) { if (validate()) { // update changes if (lmd.getLayerConfiguration().getClientLayerInfo() != null) { form.getData(); } else { form.getLayerModel(); } // persist ManagerCommandService.saveLayerModel(lmd, SaveLayerModelRequest.SAVE_SETTINGS); form.setDisabled(true); return true; } else { return false; } }
public void setUserApplicationInfo(UserApplicationInfo userApplicationInfo) { blueprint.setUserApplicationInfo(userApplicationInfo); }
public UserApplicationInfo getUserApplicationInfo() { return blueprint.getUserApplicationInfo(); }
public String getParameterValue(String key) { if (key == null || "".equals(key) || layerConfiguration == null) { return null; } else { return layerConfiguration.getParameterValue(key); } }