Skip to content

Commit

Permalink
Slight change to element canView(), to make it work the same as canUs…
Browse files Browse the repository at this point in the history
…e(), so only checks "or user field" if the group ACL does not allow.
  • Loading branch information
cheesegrits committed Dec 19, 2017
1 parent 495d8e2 commit 24c5c52
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions components/com_fabrik/models/element.php
Expand Up @@ -1017,8 +1017,8 @@ public function canView($view = 'form')
$this->access->$key = in_array($params->get($prop, $default), $groups);
}

// Override with check on lookup element's value = logged in user id.
if ($params->get('view_access_user', '') !== '' && $view == 'form')
// If no group access, can override with check on lookup element's value = logged in user id.
if (!$this->access->$key && $params->get('view_access_user', '') !== '' && $view == 'form')
{
$formModel = $this->getFormModel();
$data = $formModel->getData();
Expand Down

0 comments on commit 24c5c52

Please sign in to comment.