Hi all,
i'm using the TemplatePicker widget in the editor and want to have only one item and not the 4 i have in the layer .
has any one have an idea .
i have tried the "ITEMS" instead of the layer with no luck.
i also tried to use jquery selector to hide the other - no luck there either.
$('#ThePicker td[idx!="2"]').css("display", "none");
if anyone has suggestion ,i'll be happy to hear.
thanks
iris
Hi Iris,You can query out the layer by ID. Ex:var layersWildfire = [results.layers[1].layer]function initEditor(results) {
var layerInfosWildfire = array.map(results.layers, function(result) {
return {
featureLayer : result.layer
};
});
var layersWildfire = [results.layers[1].layer]
var tpCustom = new TemplatePicker({
featureLayers: layersWildfire,
columns: 2
}, "divLeft")
tpCustom.startup();
var editorSettings = {
map: map,
geometryService: new GeometryService("http://server/arcgis/rest/services/Utilities/Geometry/GeometryServer"),
layerInfos: layerInfosWildfire,
templatePicker: tpCustom,
}
var editorParams = {
settings: editorSettings
}
widgetEditor = new Editor(editorParams, "divTop")
widgetEditor.startup();
};