Skip to main content

Add Feature Layer in Workflow 5

Comments

19 comments

  • Jostein Svegården

    I haven't used this, but if you post your inputs to the activity, maybe someone can see if you have done any apparent mistakes

    0
  • Permanently deleted user

    I attached one here. simply connect from the Query Activity output to the Add Feature Layer input. Don't know if it should be more than that. thanks.

    0
  • Jostein Svegården

    I think your Fields input should be an array of Field objects, e.g. like this:

     

    =[{

          "name": "ObjectID",

          "alias": "ObjectID",

          "type": "esriFieldTypeOID"

         }, {

          "name": "asset_id",

          "alias": "AssetID",

          "type": "esriFieldTypeString"

         }, {

          "name": "title",

          "alias": "Title",

          "type": "esriFieldTypeString"

         }]

     

    0
  • Permanently deleted user

    Thanks @Jostein Svegården? , you're correct I didn't noticed the Fields input is actually Field objects. But it still does nothing even after I fixed the Fields input. I thought it might caused by the returned feature doesn't associate with a symbol, so I also tried to add symbol to the features, but it doesn't seem make any difference. There's no graphic added to the map, no new layer added to the Layer list, no error message. the out Layer object of the activity attached. In which I noticed the 'id' is set to the Display Name input, but the 'name' is undefined , thought not sure if that's a problem.

     

    Would be great if the support team or someone could provide a working example.

    0
  • Permanently deleted user

    I am curious about this as well. It is not working for me either. A working example would be marvelous.

     

    0
  • Permanently deleted user

    I have gotten a little farther today. I now have a feature layer added to the map - but it is not selectable, it is not in the layer list, and such, hence not very useful.

    0
  • Permanently deleted user

    My question for Support is whether this activity is even SUPPOSED to add the new feature layer to the layer list.  I hope someone can answer this.

    0
  • Permanently deleted user

    For others who have hit a wall with the Add Feature Layer Activity for the HTML 5 Viewer - this is what Support told me, so I suggest if you want this fixed, you should put contact Support and request this get fixed as otherwise it may not get addressed since the focus is more on Web : 
    As far as we're concerned, there is a bug with this activity.  In most of our supported viewers like Web AppBuilder or VertiGIS Studio Web, this activity adds the data to the map, legend, and the layer list.  The Identify tool can then return results from the new layer as well.  But in the HTML5 viewer, it only adds the features to the map and doesn't update the layer list, legend, or identifiable layers.
     
    We have the issue logged as 146401 in our internal bug tracker.  I've added this support ticket to the bug info and included your comments about the activity documentation being insufficient as well.  The more stakeholders we find affected by an issue the higher its priority will rise for a fix, so I also added info from the community threads you linked too.
     
    I'll mark the support ticket solved since there isn't anything else our support team can do at this time for the issue, but if you have any follow up questions let me know.  When the bug gets addressed, the ID 146401 will be mentioned on https://docs.geocortex.com/workflow/latest/help/Default.htm#wf5/help/release-notes.htm

    1
  • Jack Zhang

    Thanks @... for sharing on this. much appreciated

    0
  • Permanently deleted user

    It is frustrating that this feature is not resolved but the focus is likely on Web and Javascript 4.x stuff.  I ended up having to create my own faux layer list to turn different graphic layers that I had created on/off and to let me manipulate their opacity and such.

    0
  • Dean Howell

    Yes trying to do the same and would love to know more about any solutions.

    0
  • Permanently deleted user

    One of my colleagues was told by Vertigis that is would be some time before Web has all the features that Essentials/HTML5 Viewer provides (such as symbology on the fly, etc.) so to me it is critical this gets fixed. We have an open case with Support where they are looking into some solutions, so if anything comes of it, will post here.

    0
  • Niluka Munasinghe

    VertiGIS has confirmed they'll fix the issue with version 5.29. (which is supposed to release in Sep 2022)

    0
  • Niluka Munasinghe

    With the new WF 5.29 update, bug 146401 has been fixed. Now Add Feature Layer activity add the layer to the map and layer list. But I can't get any attributes with identify operation. The console doesn't show any errors. Please let me know how to get the layer attributes.

    0
  • Permanently deleted user

    We upgraded to 5.29.0 and I am still having issues with this activity.  Layer is not adding to the map and layer list and I have tried everything I can think of to get it to work.  I would be happy if I could just get the layer to add to the map. Can you share your arguments with us?  I have tried removing a questionable attribute,projecting geometry from WGS84 to Web Mercator into a new featureset, and featureset seems fine.

    But I get an error with the Add Feature Layer part. I can add the featureset's graphics to the map just fine no matter what, just can't add them to a layer to the map so they are in the layer list and map as a layer.

     

    Mine

    Features =$featureSet2.featureSet.features

    DisplayName ="Test_Layers"

    Fields:

    =[{

          "name": "OBJECTID",

          "alias": "ObjectID",

          "type": "esriFieldTypeOID"

         }, {

          "name": "name",

          "alias": "Name",

          "type": "esriFieldTypeString"     

          }]

    0
  • Permanently deleted user

    Update - I finally got it to work. My mistake was you cannot add the graphics as a graphics layer even if it is from a different featureset and then also add to layer as a map.   But I am having an issue with identify too. It needs a feature description added somehow to the layer, I think but am getting a lot further. In my case, I will have to build all that in the workflow and have it flexible enough to set the styling from the style attributes of the imported features from KMZ to the greatest extent possible. But I am much happier thus far.  We also want to use this activity to allow copy layer types of functionality.

     

    0
  • Niluka Munasinghe

    I found a workaround for identifying by using the Show Results Activity, which can set up the feature description. But not sure whether that'll be helpful in your case. 

    0
  • Permanently deleted user

    Yes, I am doing the Show Results Activity as a workaround, too, but it would still be nice if it behaved more like a real layer for identify.

    0
  • Peter Milenkovic

    Digging up an old thread!

    I got the Add Feature Layer activity to add a layer in the layer list for Essentials/HTML5 Viewer, but i cant seem to get the attributes to show when i perform an identify. Anyone get this working?

    Cheers!

     

    0

Please sign in to leave a comment.