Role Based customer emails v1.7

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
13 Jahre weitere
I am trying to send out customer order confirmations based on the customer's role.

For example, all customers receive the emails but only those capable of viewing pricing will have emails with pricing info.

Something like: Membership.GetUser().IsInRole("ShowPrice")

I use Page.User.IsInRole... within codebehinds but how would I achieve the same within MessageManager.cs?
What should I call to use the NOP membership provider?

Thanks in advance
13 Jahre weitere
StoreRoleProvider srp = new StoreRoleProvider();
                
                if ( srp.GetRolesForUser(customer email).Contains("ShowPrice"))
                
{...}

Am I close?  If so, how would I get the username?  Does it matter if my nop uses email addresses instead of usernames?
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.