Class ecm.model.Role
Extends
ecm.model._ModelObject.
Represents a role to which users or groups can be assigned.
Defined in: <ecm\model\Role.js>.
Constructor Summary
Constructor Attributes | Constructor Name and Description |
---|---|
ecm.model.Role(properties)
Constructor
|
Field Summary
Field Attributes | Field Name and Description |
---|---|
The privileges for the current user.
|
|
The role description text.
|
|
The message Id.
|
|
A boolean indicating whether the current user is an owner of this role.
|
|
A boolean indicating whether the role is predefined.
|
|
The privileges for this role.
|
- Fields borrowed from class ecm.model._ModelObject:
- categorization, id, isRecurring, name, nameFilter, pane, status, type, userId
Method Summary
Method Attributes | Method Name and Description |
---|---|
hasPrivilege(privilege)
Returns true if this item has the specified privilege.
|
|
<static> |
ecm.model.Role.Role.lookupPrivilegeDescription(privName)
Static function that returns the description for the give privilege.
|
<static> |
ecm.model.Role.Role.lookupPrivilegeLabel(privName)
Static function that returns the label for the give privilege.
|
toJSON()
Generates a JSON representation of this role.
|
- Methods borrowed from class ecm.model._ModelObject:
- destroy, getSortCriteria, onChange, own, refresh, toString
Constructor Detail
ecm.model.Role(properties)
Constructor
- Parameters:
- properties
- The properties for the model object. The properties can be any of the public fields as defined below and on ecm.model._ModelObject.
Field Detail
currentUserPrivileges
The privileges for the current user.
description
The role description text.
Defined in: <ecm\model\RedactionPolicy.js>.
Defined in: <ecm\model\RedactionPolicy.js>.
messageId
The message Id.
owner
A boolean indicating whether the current user is an owner of this role.
preDefined
A boolean indicating whether the role is predefined.
privileges
The privileges for this role.
Method Detail
hasPrivilege(privilege)
Returns true if this item has the specified privilege.
- Parameters:
- privilege
<static> ecm.model.Role.Role.lookupPrivilegeDescription(privName)
Static function that returns the description for the give privilege.
- Parameters:
- privName
- The privilege to lookup
<static> ecm.model.Role.Role.lookupPrivilegeLabel(privName)
Static function that returns the label for the give privilege.
- Parameters:
- privName
- The privilege to lookup
toJSON()
Generates a JSON representation of this role.