Pulling the user info into the app from who ran it on the gallery
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
HI All,
I am hoping this is a silly question and there if a variable/constant I can drop into the workflow for this, but I want to bring the username of who is running the app into the workflow to dictate how the workflow runs. Does anyone know what that variable might be?
Workarounds I'd like to steer clear from:
- Handling the authentication through manually maintained authentication tables that I am comparing parameters I give the user (user, pw) . Clunky and multiple areas of authentication.
- Changing configuration of gallery to prompt for credentials before running app. I believe this would also require us granting privileges on the server to run apps for each user we would do this for. And I still think I'd have to use some run command to get that user info.
Any answers here are appreciated!
Best,
Kevin
Solved! Go to Solution.
- Labels:
- Apps
- Dynamic Processing
- Gallery
- Settings
- Workflow
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi @The_Dev_Kev_Env,
You can do this with a TextBox named __cloud:UserId
There is an idea at the moment under review to include this as a constant.
Kane
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi @KaneG,
Quite the Easter Egg! Thanks for this.
One follow-up question. I am assuming the output is the subscriptionID of the user and I am trying to map that to the user collection in the MongoDB. What I am seeing is that the subscriptionID that is outputted and the one in the collection are off by the last digit (numerically a diff of 1-5). I'm wondering if this is a case of updated subscriptions/versioning...
Have you seen this before? Is this also the suggested route in getting the user information (joining ID to Mongo instance).
Gallery Output:
Mongo output:
Best,
Kevin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi Kevin,
I have several app/gallery/collection reports I built. What exactly are you trying to do? Joining between different Mongo Collections can get convoluted very fast!! If I knew exactly, I might have something already built that I can look into and let you know.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi @mbarone,
Thanks for the response. Actually came across a different thread where you provided a workflow to the parse through the user collection and grab the user id. Implemented that and works a like a charm.
Best,
Kevin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Great, glad to hear it!!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
@mbaroneone more quick question.
Are there other similar functions to the __cloud:UserId. In particular, can I get the collection information from where the app is being run from?
Best,
Kevin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
I only know about the cloud ID. I think they're talking about adding a bunch more at some point in the future.
For Collections, I have a separate app that I run in the Gallery to see the different permutations of Collections/Users/App. If it seems like something that might work for you, let me know:
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi @The_Dev_Kev_Env,
It would be really useful if you could link to the solution you found for this. This issue is marked as 'solved' on the community but others are not able to find the answer from this thread.
Cheers,
Luke
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
@mbarone Would you mind sharing your Collections app? I'm looking to write the name of the workflow in addition to the user info to a sql server db table. Is there a way to capture the workflow name in the gallery?
