I want to create simple web app in Web AppBuilder Developer Edition 2.0.
The app should combine an ArcGIS Server service and a secured WMS.
My organization uses Portal for ArcGIS 10.3.1 so I'm not able to add a secured WMS as an item in Portal.
I think I can add secured WMS following the way presented in this example:
Custom layer - WMS | ArcGIS API for JavaScript 3.17
Which files generated by the Web AppBuilder should I modify to add custom content which cannot be adde to Portal items?
According to the example above I'll have to use addLayer method among others.
"My organization uses Portal for ArcGIS 10.3.1 so I'm not able to add a secured WMS as an item in Portal.
Why not? Add layer from Web >> A WMS Web Service is available in 10.3.
Alternately, you could look at the LocalLayer widget.
Come on, do you think I didn't try first?
I've also read that secured WMS are supported from Portal 10.4.
I'll try with the LocalLayer widget.
my apologies.
10.4
after looking, I dont think LocalLayer will be useful for your situation .
You were on the right track with the JS API
There is an add data widget(arcgis.com), could you have a play and check whether it's what you want?
Unfortunately https:// WMS service is 'unsupported' in this widget.
Moreover, added URLs are not saved in the map.
I've also found Add Service Widget - but it also doesn't support secured WMS.
So, we've found there's rather no widget which can help.
I was able to display secured WMS using JS API (with standard WMSLayer).
But I still have no idea which files generated by WAB should I modify to insert my code. Any ideas?
In jimu.js/MapManager, at line 269, the map object is created. I think you can add your layers here.
I was looking to similar kind of issue like adding secured wms layer from geoserver to map using Esri Js API.. Can you please provide help with that. Thanks
Michal, I've found that I need to make the map in Portal, where you can add a service by using its url. Then you make the web map app from the Portal map. I hope that helps.