I'd like to check the current user's groups, and if they are a memeber
of a certain list of groups set a flag that I can use pretty much
anywhere. Where is the best place/scope (session,request??) to set
this... for example.
for exmaple, if I set this in the dmheader.cfm include, it does nto
seem to "always" be available.. (ie search results, etc.)
<cfparam name="WHATSCOPE??.VIP" default="0">
<!--- determine the policy groups (or roles) this user belongs to --->
<cfif isDefined("session.dmsec.authentication.lPolicyGroupIDs") and
listLen(session.dmsec.authentication.lPolicyGroupIDs)>
<!--- concatenate logged in group permissions with anonymous group
permissions --->
<cfset lpolicyGroupIds = session.dmsec.authentication.lPolicyGroupIDs
& "," & application.dmsec.ldefaultpolicygroups>
<!--- check for sales partners access --->
<cfset lVIPGroupIDs = "18,10">
<cfloop list="#lVIPGroupIDs#" index="i">
<cfif listfind(session.dmsec.authentication.lPolicyGroupIDs,i)><cfset
WHATSCOPE??.VIP = 1></cfif>
</cfloop>
<cfelse>
<!--- user not logged in, assume anonymous permissions --->
<cfset lpolicyGroupIds = application.dmsec.ldefaultpolicygroups>
</cfif>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"farcry-dev" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/farcry-dev?hl=en
-~----------~----~----~----~------~----~------~--~---