Hi All,
This is the workflow I am looking to accomplish:
Issue: FeatureLayer Permissions. We don't care about everyone having view access to the layer. We do care about everyone having edit rights. If we restrict the Feature Layer Permissions in Portal to a specific Group, the URL hyperlink, generates with ?token=zzz. We want the FeatureLayer image urls to not require a token, which the only way I can see to fix that is sharing it with everyone, which implicitly gives everyone edit rights.
Is there a way to configure a FeatureLayer to be globally viewable, but editable only to those who are members of a group in portal?
Or
Is there a way to configure Survey123 to upload/host images somewhere else?
Thanks!
Hi John,
It sounds like you might want to take advantage of feature service views to provide access, assuming you are using Enterprise 10.6 or later (Create hosted feature layer views—Portal for ArcGIS | ArcGIS Enterprise ). One way to do this is to share the survey for viewing in the Survey123 website - that will create a feature service view that is read only, but points to the same tables as the editing. You could then share that to everyone and base the link off the service URL of that view; this would allow you to keep the editing feature service limited to the editor group.
Hi James,
I had messed with views, but didn't realize you could create the view directly from Survey123. That was a super helpful, Thanks! I think I'm incredibly close to getting it set up to do what we need. I'll spell out what I'm doing in the off-chance it helps someone else out
1. Survey123 Data is updated by a Field Operator and an image is attached. It's added to the Surveys Submitter Feature Layer
2. Under Survey123 -> Collaborate -> Viewer, set viewer to everyone and Save. This builds a new stakeholder Feature Layer hosted view
3. The fieldworker view (Collaborate -> Submitter in Survey123), which is editable to my organization only, will have an additional field and field calculator script that generates a URL that references the attachments in the stakeholder (read only shared with everyone) view . Script would do something like this:
oid = !ObjectID! def MakeURL(oid) : userImg= 'https://services1.arcgis.com/xxx/ArcGIS/rest/services/survey123_xx_stakeholder/FeatureServer/0/'+str(oid)+'/attachments/'+str(oid) return userIMG
The end result should be a link to an attachment that was previously restricted, requiring token, and consumers can make no edits.
Thanks for the direction!
Resolved this. Ended up being very straightforward. Update script at the end is not production ready, but worked for the proof of concept I had to demo: