|
POST
|
The Javascript API can be pretty bad at rendering complicated symbology on FeatureLayers; Unfortunately this might be what you're running up against. One sneaky way to do it is to add the same service as a MapService, so that the layer gets rendered properly on the server-side, and also add the same layer as a FeatureService, but give it an empty or invisible symbology. This makes the layer selectable, and you get to see your complex symbology from the MapService layer. Just a thought.
... View more
08-26-2016
02:16 PM
|
1
|
4
|
1807
|
|
POST
|
Hey all, hope things are well. I'm finding some interesting differences between the capabilities of tokens returned from ArcGIS Online via App Login and User Login, and I'd like to get some feedback on potential alternate ways of doing things. My understanding is that an App Login is essentially an anonymous login to whatever user the App has been registered with. As a result, when your app's identityManager has been fed a credential generated via App Login, your app should be able to 'see' whatever ArcGIS Online items that the user who registered the app is able to see, even if not publically shared. I am finding that this seems to work when using the arcgisUtils.getItem() method on an ArcGIS Online item which has been shared to the registering user, albeit not to "Everyone", but I am unable to query Group Items using this token via the http://www.arcgis.com/sharing/rest/search? endpoint, or list the contents of a folder via http://www.arcgis.com/sharing/rest/content/users/<registeringUserName>/, unless the contents of that folder or group have been shared to Everyone. Tokens generated via User Login can query Folder Contents and Group Contents regardless of whather or not the contents have been shared to Everyone. This does make sense considering the Limitations described in the documentation (Limitations of App Login | ArcGIS for Developers 😞 Tokens obtained by applications can only read public content and services. Although this does seem odd because the getItem method appears to work on individual items. Any thoughts on a potential way to use an App Login and have the ability to list/query non-public Folder and Group contents? Any thoughts on issues/limitations with dedicating a Named User specifically to a single app, and simply using it as a quazi-App-Login through a proxy? Just tossing it out there.
... View more
08-23-2016
12:50 PM
|
0
|
0
|
1686
|
|
POST
|
Have you made the code change to your AttributeTable Widget described here, Babatope? What version of the WebAppbuilder are you using? From your posts above, it sounds like you're able to configure the AttributeTable widget for your LocalLayer layers, but your configuration isn't actually being used by the application, does this sound correct?
... View more
08-15-2016
10:24 AM
|
1
|
0
|
1671
|
|
POST
|
Hey Babatope, try removing the Attribute Table from your App entirely before adding and configuring the LocalLayer widget. Make sure that the actual Configuration file for the Attribute Table widget under the /configs/ folder is gone. It's been awhile since I tried this, but I think when you re-add the Attribute Table widget after configuring LocalLayer, it will instantly read any layers present in the map and give you some visibility/configuration options for your LocalLayer layers. Let us know if this works!
... View more
08-05-2016
06:15 AM
|
0
|
2
|
1671
|
|
POST
|
Thanks Rebecca; Reading your helpful document, I'm encouraged to see that this functionality is on Esri's radar for WAB as well. At the very least, hopefully this widget can be a get-you-by until Related Editing functionality is built into the WAB by default.
... View more
06-15-2016
08:29 AM
|
0
|
2
|
2667
|
|
POST
|
June 17th 2016: Just a note that I've put a flavour of the Batch Attribute Editor up that should allow for batch editing of related fields. Note that it's still in preliminary/proof-of-concept stages and would also benefit from adventurous testers. https://github.com/cmndrbensisko/BatchEditRelated Hey all, hope things are well. I'm not sure if someone else has encountered a similar business case, but we've run into situations where Client A would like to add a new field to Client B's dataset, which Client A would then be responsible for maintaining. Instead of fully duplicating Client B's dataset just so that Client A can own and manage a single attribute, a more elegant solution might involve Relating a Table containing just the desired attribute and a foreign key to Client B's dataset via a 1:1 relationship, and then having Client A simply own and manage the Related Table. A problem arises when we want Client A to be able to edit their related table via a FeatureService, or through the WAB in particular. When using the built-in Editor widget to edit a feature, related fields aren't displayed for editing. I've cobbled together a preliminary Edit widget which should allow you to edit any attributes (Except OIDs and Foreign Keys) within a related table in Web Appbuilder, provided that the relationship is 1:1. Within the Editor popup, related fields should just be appended to the bottom of the field list. If no related record exists for the currently-selected feature, a new record in the Related Table will be created for this feature once any related attributes are changed or updated via the popup, at which point any changes will be treated as typical updates. It isn't highly polished yet, but feel free to experiment a bit with its capabilities and I can potentially expand it to apply to other business cases as well. I'm not too familiar with cases where Relates and Web Editing could be usefully used together. This tool has been tested to work with the LocalLayer widget. https://github.com/cmndrbensisko/EditRelated
... View more
06-15-2016
07:35 AM
|
3
|
9
|
6359
|
|
POST
|
Version 2.0 has been released. Give it a try Mike; You'll likely still encounter the same menu issue from before. I'm sure I'll eventually fix that menu, but I tend to just write in the field name myself.
... View more
05-18-2016
08:23 PM
|
0
|
0
|
1641
|
|
POST
|
It looks like I didn't have autorefresh capability enabled properly for Dynamic Mapservices, thanks for finding this Michael. Give the candidate version below a try. Note that you should also be able to specify decimal values for the timeout if you want it to be less than a minute before refreshes. GitHub - cmndrbensisko/LocalLayer at LocalLayer2.0
... View more
05-09-2016
02:58 PM
|
0
|
2
|
1641
|
|
POST
|
Good catch! I hadn't revisited the text of the original post since it originally went out over a year ago. Hopefully it hasn't dissuaded anyone from using the widget, but I've updated the post accordingly.
... View more
05-06-2016
06:53 AM
|
0
|
0
|
1510
|
|
POST
|
Hey William, I've just slipped a simple fix into the candidate that should enable Viewing Attachments on Dynamic Layers. Feel free to give it a try on your end. GitHub - cmndrbensisko/LocalLayer at LocalLayer2.0
... View more
05-04-2016
09:05 AM
|
0
|
0
|
1510
|
|
POST
|
Hey William, thanks for your post. I don't think we've done much to crack the attachment nut yet, but we can certainly take a swing at this in the latest candidate widget. To make testing easier, do you happen to have a public-facing MapService with attachments?
... View more
05-03-2016
08:03 AM
|
0
|
0
|
1510
|
|
DOC
|
Haven't tried Robert, but I think the three "-1"s are necessary. If you peek into jimu.js/LayerInfos/LayerInfoForMapService.js, you can see it gets pretty nutty. Line 633: if(visibleLayers[0] === -1 && visibleLayers[1] === -1 && visibleLayers[2] === -1) { this._subLayerVisibleChanged(); this._isShowInMapChanged2(); return; } Line 644: var visibleLayersForSetVisibleLayers = [-1, -1, -1]; Line 211: var ary = [-1, -1, -1], index; The WAB really seems to be marching to the undocumented beat of its own drummer on these; The best I think we can try to do in our own widgets is emulate it as best as possible.
... View more
04-22-2016
10:30 AM
|
0
|
0
|
26300
|
|
DOC
|
I've run into this kind of behaviour before with the LocalLayer widget. It seemed like the Web AppBuilder's idea of a 'visible layer' differs somewhat from what's described in the API doc. Currently, the SaveSession widget attempts to 'set' layer visibility using the following code on line 615 of Widget.js: if (layerSettings.visibleLayers && layer.setVisibleLayers) { layer.setVisibleLayers(layerSettings.visibleLayers); } For some reasons related to how the jimu.js libary interprets layer visibility, I'm finding that changing this section to use the code below results in the LayerList widget 'properly' interpreting which layers should currently be visible. This code is similar to some code we use in the LocalLayer widget as well to accomplish the same purpose. As an example of the WAB's oddness, note that in order to properly interpret a layer as truly 'off', it requires an array consisting only of three '-1' values. Any light that could be shed on this by anyone would be great! if (layerSettings.visibleLayers && layer.setVisibleLayers) { var visibleLayers = lang.clone(layerSettings.visibleLayers); if (layerSettings.visibleLayers.length == 0) { visibleLayers = []; visibleLayers.push(-1); visibleLayers.push(-1); visibleLayers.push(-1); }else{ var removeItem = [] array.forEach(visibleLayers,function(visibleLayer, index){ if (visibleLayer == -1){ removeItem.push(index) } }) for (var i = removeItem.length; i-- > 0;){ visibleLayers.splice(i, 1) } } layer.setVisibleLayers(visibleLayers); } In any case, this enhanced code works well for me. If other adventurous people want to give it a try, I'd be happy to fork the repo for an enhancement if it would benefit the widget.
... View more
04-22-2016
08:37 AM
|
3
|
0
|
26300
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 05-13-2024 08:42 AM | |
| 1 | 02-07-2024 07:51 AM | |
| 1 | 02-07-2024 08:35 AM | |
| 1 | 07-26-2023 01:07 PM | |
| 1 | 08-10-2017 03:33 PM |
| Online Status |
Offline
|
| Date Last Visited |
05-22-2024
09:28 AM
|