Set User Model Id to running user ONLY if no URL parameter provided on the skuid page?

We have a use case where we want to set the user model id to a url parameter “teammember” but if this is not provided at all then use the usual running user as the Id

It will allow us to them use one page for a dashboard with charts on running user or their team mates if necessary

Cant seem to find a workaround.

Any ideas would be appreciated

  1. I think you will need to do the following.

    Set User model NOT to load on page load. (and probably cascade that down to other models that depend on the User model)

  2. Create an "on page load" action sequence that branches on the parameter. (page parameters are accessible in merge syntax in branching formulas). One branch sets user model condition to "teammember" the other sets it to "{{$User.userId}}" - after setting the condition each branch queries the model...

After that - all that’s left to do is bask in the adulation of your fans…

Let me know if this sketch doesn’t make sense.

That sounds like a perfect solution!

Thanks again.