|
POST
|
After looking into this a little further, I've found the Search widget calls the locator.suggestLocations method, which returns an array of SuggestionResult objects that differ slightly than the SuggestResult objects you mentioned above. These SuggestionResult objects do contain the isCollection property, but that information gets lost in esri/widgets/Search/support/locatorUtils when they get transformed into SuggestResult objects. @Noah-Sager any chance that isCollection values can get carried over into SuggestResult?
... View more
09-06-2022
10:31 AM
|
0
|
0
|
3152
|
|
POST
|
If there's no means of telling the server not to return keyword results, then the alternative would be to strip them out from the response before that response is received by the Search widget. Have you considered using a RequestInterceptor? These can be added via the esriConfig.request property. Using this, you can examine the suggestions in the response, and strip out any that have isCollection set to true before the widget receives those results. Since some results are therefore likely to be stripped out, you might also consider increasing your maxSuggestions setting.
... View more
09-01-2022
10:36 AM
|
1
|
2
|
3166
|
|
POST
|
I think you can fix this by not setting the FeatureLayer's outFields to ["*"]. Instead, I believe you should limit the outFields to just the ones you want to search, .e.g ["name","alternate"].
... View more
08-23-2022
10:29 AM
|
1
|
0
|
1094
|
|
POST
|
Without seeing your code, it's impossible to tell what's causing the problem. However, to accomplish what you're trying to do, I would recommend something like the following: var mapCenter = map.extent.getCenter();
var screenCenter = map.toScreen(mapCenter);
console.info(screenCenter.x.toString() + ", " + screenCenter.y.toString());
... View more
08-22-2022
04:38 PM
|
0
|
0
|
1018
|
|
POST
|
I think this may be what you're looking for (may need to double-check my typing for that URL though): const popupStreets = {
"title": "Click to report an issue:",
"content": [{
type: "text",
text: "<b>Street:</b> {SITE_NAME}<br><b>Town:</b> {TOWN_NAME}<br>" +
"<a href=\"https://east-riding-self.test.achieveservice.com/service/Map__ArcGIS_Online_Trees" +
"?street={SITE_NAME}&town={TOWN_NAME}&USRN={SITE_CODE}&assetID={CENTRAL_ASSET_ID}" +
"&Easting={FEAT_CENT_EAST}&Northing={FEAT_CENT_NORTH}\" rel=\"nofollow ugc\">" +
"<font size=\"6\">Click Here</font></a>"
}, {
type: "custom",
creator: (graphic) => {
const location = view.popup.location;
return `X: ${location.x.toFixed (0) }<br>Y: ${location.y.toFixed (0)}`; //gets x/y coordinates
}
}]
}; The most likely issue you were having is needing to escape the quotation marks surrounding the html element attributes, since this text is already inside of a JavaScript literal. When inside a JavaScript string, if you want a quotation mark in the string, you have to add a backslash before it, like: \"
... View more
08-11-2022
10:12 AM
|
1
|
0
|
3896
|
|
POST
|
Ok...I was assuming you already had it set up with each territory layer only having the expected features. In this case, for each layer, you'd also need to filter only the features you want. You can accomplish this by setting the definitionExpression and (possibly) the fullExtent properties. If using only the definitionExpression, the smallest possible value could still become quite large. Therefore, a possible alternative would be using the fullExtent to define the MBR for the features you want, and then using definitionExpression to remove the "extras", which could dramatically reduce the size of the definitionExpression.
... View more
08-08-2022
03:01 PM
|
0
|
1
|
3554
|
|
POST
|
It seems to me that if you broke the territories out into individual layers (like you already mentioned), but used a SimpleRenderer instead, you would get much better performance, since that would result in 15 symbols rather than 27,000.
... View more
08-08-2022
01:27 PM
|
0
|
3
|
3577
|
|
IDEA
|
My apologies...didn't realize this was in the ideas section. Hope my reply helps though...
... View more
08-05-2022
10:45 AM
|
0
|
0
|
2600
|
|
IDEA
|
As already pointed out in another thread, the layer order in the Legend is going to match the layer order of the map. Therefore, if you're going to accomplish what you've described, you're going to have to use more than one Legend control. In our framework, we create a Legend for each individual layer, and are then free to display those individual Legends in whatever order we see fit.
... View more
08-05-2022
10:34 AM
|
0
|
0
|
2605
|
|
POST
|
One thing I see is that the line with window.setTimeout should instead be: window.setTimeout(stepThroughGraphics.bind(window, view, graphics, index), 2000); (forgot about that first argument in the call to bind...)
... View more
08-03-2022
12:32 PM
|
1
|
0
|
2104
|
|
POST
|
Perhaps something like the following: function stepThroughGraphics(view, graphics, index) {
if (index < graphics.length) {
var geometry = graphics[index++].geometry;
view.goTo({
center: [geometry.longitude, geometry.latitude],
zoom: 4
},{
duration: 30000,
maxDuration: 30000
}).then(function() {
window.setTimeout(stepThroughGraphics.bind(view, graphics, index), 2000);
});
} else
loading = "done";
}
//etc
view.whenLayerView(featureLayer).then(function(layerView) {
layerView.watch("updating", function(value) {
if (!value) {
// wait for the layer view to finish updating
if (loading != "done") {
// query all the features available for drawing.
layerView.queryFeatures({
geometry: featureLayer.extent,
returnGeometry: true
}).then(function(results) {
stepThroughGraphics(view, results.features, 0);
}).catch(function(error) {
console.error("query failed: ", error);
});
}
}
});
});
... View more
08-03-2022
11:34 AM
|
1
|
2
|
2118
|
|
POST
|
I haven't tested this, but it seems to me you could use a WebTiledLayer and override the getTileURL function like so: var layer = new WebTiledLayer({
id: "myLayerID",
visible: true,
urlTemplate: "http://maps.customweather.com/cw_tiles/5-5imZ7MogxLQSd-NFMPy5aPfZAEBj3axcJeJeBh38PtBSPb_cgTvhRqEAQhlNSI/synoptic_temp/{level}/{col}/{row}.png"
});
layer.getTileUrl = function(zl, ty, tx) {
var quad = "";
for (var i = zl; i > 0; i--) {
var mask = 1 << (i - 1);
var cell = 0;
if ((tx & mask) != 0) {
cell++;
}
if ((ty & mask) != 0) {
cell += 2;
}
quad += cell;
}
return "http://maps.customweather.com/cw_tiles/5-5imZ7MogxLQSd-NFMPy5aPfZAEBj3axcJeJeBh38PtBSPb_cgTvhRqEAQhlNSI/synoptic_temp/" + quad + ".png";
}; Note that the urlTemplate value in the constructor is bogus, but that's ok because it will never be used.
... View more
07-25-2022
07:45 PM
|
1
|
0
|
1328
|
|
POST
|
The main problem with this is that in 4.x FeatureLayers, you don't have direct access to the Graphic (i.e. feature) objects that are displayed on the map. The features returned by queryFeatures are a copy of the actual features, and so modifying them won't make any difference to the layer itself. One of the best ways to accomplish what you're trying to do may be to query the features (as you're doing), but then set their symbol property directly, and then add them to a separate GraphicsLayer.
... View more
07-14-2022
10:00 AM
|
0
|
0
|
993
|
|
BLOG
|
Got it...thanks also for decreasing the wait time from 3 weeks down to 2 for this release.
... View more
07-07-2022
03:01 PM
|
0
|
0
|
2050
|
|
BLOG
|
The release notes indicate the downloads would be available July 6 (yesterday), but they are still not presently listed on the download site. Is there a new ETA?
... View more
07-07-2022
11:01 AM
|
0
|
0
|
2063
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 03-19-2024 10:37 AM | |
| 1 | 03-31-2026 02:34 PM | |
| 1 | 12-09-2025 09:35 AM | |
| 2 | 12-09-2025 09:06 AM | |
| 1 | 11-26-2025 12:29 PM |