public static bool IsSalesDirector(this UserDetailsModel user) { var privileges = new string[] { "MNGALLSLSTMS" }; return(user.UserPrivileges.Any(a => privileges != null && privileges.Any(b => b == a)) && !user.Roles.Contains("BusinessAdmin")); }
public static bool HasAllAccountReadPrivilage(this UserDetailsModel user) { return(user.UserPrivileges.Contains("RDACNTALL")); }
public static bool HasAllLeadReadPrivilage(this UserDetailsModel user) { return(user.UserPrivileges.Contains("RDLDALL")); }
public static bool IsSalesRep(this UserDetailsModel user) { return(user.IsRep); }
public static bool IsSalesManager(this UserDetailsModel user) { return(user.IsSalesManager && !user.IsBuzAdmin()); }
public static bool IsBuzAdmin(this UserDetailsModel user) { return(user.Roles.Contains("BusinessAdmin")); }