/** * Add the given itemid, entityid, permission mapping. * (Session based permissions; permission is granted when this entityId is added to * GALLERY_PERMISSION_SESSION_KEY array in the session) * * @param int $itemId the id of the GalleryItem * @param int $entityId the id of the GalleryEntity * @param string $permission the permission id * @param boolean $applyToChildren (optional) whether or not this call applies to child items * @return GalleryStatus a status code */ function addEntityPermission($itemId, $entityId, $permission, $applyToChildren = false) { MyOOS_CoreApi::requireOnce('modules/core/classes/helpers/GalleryPermissionHelper_advanced.class'); return GalleryPermissionHelper_advanced::addEntityPermission($itemId, $entityId, $permission, $applyToChildren); }