Mixed Case Sharing option


(Mazen AlAli) #1

Hi guys,

I know that case sharing works by storing the user group’s id into the owner ID, and internally checks if the current user is in that group. that works. it’s fantastic.

here’s my scenario that may be unnecessarily complicated, but i’m wondering if i could pull if off anyway.

In my one application, i’m handling 4 types of cases. case sharing is active on the application level.
I have added a manual field where you can select a username that get’s stored in the property “last_user”
i want to make a case list that will only show me cases where the last_user property is equal to the username of the current user.

I know i have to put this in the filter field, i have to define a filter that says something like “last_user = /data/meta/username” but i can’t seem to figure out the right syntax. it’s throwing an error. I’m trying to get the currently logged username in the case list screen. I have no problems using this syntax inside a form. i’m guessing cause of the “data/meta/” tags

is it at all possible in a case list screen as far as you know guys?

Mazz


(Clayton Sims) #2

Hi Mazz,

When you are outside of a form, you’ll need to directly reference metadata (like the current user’s username or ID) from the Session Instance, which should let you define the filter you are describing.

You can test the expressions in that page of instance inside of a form if you want to identify what values are returned to help identify what to match them up with.

Hope that helps!

-Clayton


(Mazen AlAli) #3

that’s great! thanks Clayton, resident forum superhero


(Clayton Sims) #4

No sweat, hope that helps.

Glad to hear you’re finding the features to distribute and manage cases between users to be useful! I think they’re a big part of the value of the platform.

-Clayton


(Mazen AlAli) #5

yeah!

I’m basically defaulting cases to be managed by the person who created them, but giving a supervisor level account the option to change that person. case sharing is active, but with a filter on caselists i can limit access to the cases.

thanks again

Mazz