Skip to main content
Skip table of contents

ActionModel

A model for mapping permission key information. It uses values from configuration 'permissions/mapping'.

implements: hash
bundle: standard portal bundle
since 2.0.0
A model for mapping permission key information. It uses values from configuration 'permissions/mapping'.

Defined hash keys

canAnonymousUserComment ↦ boolean
since 2.0.82
get if comments can be added by anonymous users

canAnonymousUserLikeDisLike ↦ boolean
since 2.0.82
get if like-dislike can be done by anonymous users

canAnonymousUserRating ↦ boolean
since 2.0.82
get if rating can be done by anonymous users

canAnonymousUserViewComment ↦ boolean
since 2.0.82
get if comments can be shown to anonymous users

canBookmark ↦ boolean
since 2.0.82
get if bokmarking can be done by the current session

canComment ↦ boolean
since 2.0.0
get if comments can be added by the current session

canDislike ↦ boolean
since 2.0.0
get if dislike can be added by the current session

canEditComment ↦ boolean
since 2.0.0
get if comments can be edited by the current session

canFollow ↦ boolean
since 2.0.0
get if follow can be done by the current session

canLike ↦ boolean
since 2.0.0
get if likes can be added by the current session

canLikeDislike ↦ boolean
since 2.1.42
get if like-dislikes can be changed by the current session

canRate ↦ boolean
since 2.0.82
get if rating can be done by the current session

hasLock.<String:hashKey> ↦ Boolean
since 5.2.0
Check if the value accessed by the hash-key 'hashKey' within this model is secured by an active lock by permission rights management

  • Example:
    model.hasLock.elem - is elem in model guarded by an active permission lock?
    article.hasLock.text - Returns if there is a permission lock for text configured in 'article' ? (In this example 'article' is of of type ArticleModel)

isLocked.<String:hashKey> ↦ Boolean
since 5.2.0
Check if the value accessed by the hash-key 'hashKey' within this model is is locked for current user by permission rights management

  • Example:
    model.isLocked.elem -- is value for elem in model locked for current logged-in user?
    article.isLocked.text -- Returns if the value for 'text' within 'article' is locked (not accessible) for current user. (In this example 'article' is of of type ArticleModel)

mediaportalDownloadFreely ↦ boolean
since 2.0.0
get if media portal assets may be downloaded freely by the current session

Permission Verbs used

asset.canAnonymousUserComment
since 2.0.82 'asset.canAnonymousUserComment' - guards requests to '→canAnonymousUserComment'

asset.canAnonymousUserLikeDisLike
since 2.0.82 'asset.canAnonymousUserLikeDisLike' - guards requests to '→canAnonymousUserLikeDisLike'

asset.canAnonymousUserRating
since 2.0.82 'asset.canAnonymousUserRating' - guards requests to '→canAnonymousUserRating'

asset.canAnonymousUserViewComment
since 2.0.82 'asset.canComment' - guards requests to '→canAnonymousUserViewComment'

asset.canBookmark
since 2.0.82 'asset.canBookmark' - guards requests to '→canBookmark'

asset.canComment
since 2.0.0 'asset.canComment' - guards requests to '→canComment'

asset.canDislike
since 2.0.0 'asset.canDislike' - guards requests to '→canDislike'

asset.canEditComment
since 2.0.0 'asset.canComment' - guards requests to '→canEditComment'

asset.canFollow
since 2.0.0 'asset.canFollow' - guards requests to '→canFollow'

asset.canLike
since 2.0.0 'asset.canLike' - guards requests to '→canLike'

asset.canLikeDislike
since 2.1.42 'asset.canLikeDislike' - guards requests to '→canLikeDislike'

asset.canRate
since 2.0.82 'asset.canRate' - guards requests to '→canRate'

asset.likeUrl

asset.mediaportalDownloadFreely
since 2.0.0 'asset.mediaportalDownloadFreely' - guards requests to '→mediaportalDownloadFreely'

Methods

likeUrl(String:mode, String:variant, Boolean:other, String:group)String
since 2.3.10
Return a relative url with a csrf signature parameter ('__req_s') to used for like / dislike actions.
First parameter must be 'like' or 'dislike' setting the operation mode.
Second is a value for the variant provided as String.
Third parameter is a Boolean included into req-parameter 'like.showX'; with X is the opposite action mode.
Last parameter is optional the navigation group (with default value 'like-ajax-group') defining how to find the NavigationTreeNodeModel the URL resolves to.
Parameters set on URL:

param
values
remarks
__req_s*csrf signature value
like.variant*copy of second parameter
like.showDislike'true''false'if mode 'like', value from third param
like.showLike'true''false'if mode 'dislike', value from third param
like.action'false'if mode 'dislike'
JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.