Class ModulePermissionHelper
- Namespace
- Dynamicweb.Modules
- Assembly
- Dynamicweb.dll
public class ModulePermissionHelper
- Inheritance
-
ModulePermissionHelper
- Inherited Members
Properties
ModuleService
[Obsolete("Use ModuleService instead.")]
public static IModuleService ModuleService { get; }
Property Value
Methods
GetPermission(Module)
Gets the PermissionLevel for the Module.
public static PermissionLevel GetPermission(Module theModule)
Parameters
theModule
Module- The module.
Returns
- PermissionLevel
- The permission level for current user.
HasAccess(string)
Determines whether user has access to a specified module.
public static bool HasAccess(string moduleSystemName)
Parameters
moduleSystemName
string- The module system name.
Returns
HasPermission(Module, PermissionLevel)
Determines whether user has a specified permission level for a module.
public static bool HasPermission(Module theModule, PermissionLevel level)
Parameters
theModule
Module- The module.
level
PermissionLevel- The minimum required permission level.
Returns
- bool
True
, if current user has permission, otherwiseFalse
.
HasPermission(string, PermissionLevel)
Determines whether user has a specified permission level for a module.
public static bool HasPermission(string moduleSystemName, PermissionLevel level)
Parameters
moduleSystemName
string- The module system name.
level
PermissionLevel- The minimum required permission level.
Returns
- bool
True
, if current user has permission, otherwiseFalse
.