- Модуль: tasks
- Путь к файлу: ~/bitrix/modules/tasks/lib/checklist/checklistfacade.php
- Класс: BitrixTasksCheckListCheckListFacade
- Вызов: CheckListFacade::fillActionsForItems
static function fillActionsForItems($entityId, $userId, $items)
{
if (empty($items))
{
return $items;
}
$items = array_map(
static function($item) use ($entityId, $userId)
{
$item['ACTION'] = [
'MODIFY' => static::checkAccess($entityId, $userId, ActionDictionary::ACTION_CHECKLIST_EDIT, $item),
'REMOVE' => static::checkAccess($entityId, $userId, ActionDictionary::ACTION_CHECKLIST_EDIT, $item),
'TOGGLE' => static::checkAccess($entityId, $userId, ActionDictionary::ACTION_CHECKLIST_TOGGLE, $item),
];
return $item;
},
$items
);
return $items;
}