domain: client
language: javascript
class AbstractItem
Use can_view method to determine if a user have a right to get access to an item dataset or to see report generated by report when the project Safe mode parameter is set. If the project Safe mode parameter is not set the method always returns true.
The user privileges are set in the roles node of the project tree.
if (item.visible && item.can_view()) {
$("#submenu")
.append($('<li></li>')
.append(
$('<a href=""></a>')
.text(item.item_caption)
.data('item', item);
)
);
}