Class Permission
Permission information for anything in Oqtane. Things in Oqtane are identified as Entities, so anything that can be identified can be described here.
public class Permission : ModelBase, IAuditable
- Inheritance
-
Permission
- Implements
- Inherited Members
Constructors
Permission()
public Permission()
Permission(int, string, int, string, string, int?, bool)
public Permission(int siteId, string entityName, int entityId, string permissionName, string roleName, int? userId, bool isAuthorized)
Parameters
siteId
intentityName
stringentityId
intpermissionName
stringroleName
stringuserId
int?isAuthorized
bool
Permission(int, string, string, string, int?, bool)
public Permission(int siteId, string entityName, string permissionName, string roleName, int? userId, bool isAuthorized)
Parameters
Permission(string, int, bool)
public Permission(string permissionName, int userId, bool isAuthorized)
Parameters
Permission(string, string, bool)
public Permission(string permissionName, string roleName, bool isAuthorized)
Parameters
Properties
EntityId
ID of the Entity these permissions apply to (ie. a ModuleId). A value of -1 indicates the permission applies to all EntityNames regardless of ID (ie. API permissions)
public int EntityId { get; set; }
Property Value
EntityName
Name of the Entity these permissions apply to (ie. Module )
public string EntityName { get; set; }
Property Value
IsAuthorized
The type of permission (ie. grant = true, deny = false)
public bool IsAuthorized { get; set; }
Property Value
PermissionId
Internal ID storing this information.
public int PermissionId { get; set; }
Property Value
PermissionName
Name of the permission (ie. View)
public string PermissionName { get; set; }
Property Value
Role
[Obsolete("The Role property is deprecated", false)]
[NotMapped]
[JsonIgnore]
public Role Role { get; set; }
Property Value
RoleId
public int? RoleId { get; set; }
Property Value
- int?
RoleName
The role name associated to the RoleId.
[NotMapped]
public string RoleName { get; set; }
Property Value
SiteId
Reference to the Site which contains both the target Entity and permissions.
public int SiteId { get; set; }
Property Value
UserId
public int? UserId { get; set; }
Property Value
- int?
Methods
Clone()
public Permission Clone()