| @@ 750-752 (lines=3) @@ | ||
| 747 | return false; |
|
| 748 | } |
|
| 749 | ||
| 750 | if (!empty($this->managerOptions['options']['access']['apps']) && !in_array(\App::$cur->name, $this->managerOptions['options']['access']['apps'])) { |
|
| 751 | return false; |
|
| 752 | } |
|
| 753 | if (!empty($this->managerOptions['options']['access']['groups'])) { |
|
| 754 | return in_array(\Users\User::$cur->group_id, $this->managerOptions['options']['access']['groups']); |
|
| 755 | } |
|
| @@ 753-755 (lines=3) @@ | ||
| 750 | if (!empty($this->managerOptions['options']['access']['apps']) && !in_array(\App::$cur->name, $this->managerOptions['options']['access']['apps'])) { |
|
| 751 | return false; |
|
| 752 | } |
|
| 753 | if (!empty($this->managerOptions['options']['access']['groups'])) { |
|
| 754 | return in_array(\Users\User::$cur->group_id, $this->managerOptions['options']['access']['groups']); |
|
| 755 | } |
|
| 756 | if ($this->managerName == 'manager' && !\Users\User::$cur->isAdmin()) { |
|
| 757 | return false; |
|
| 758 | } |
|
| @@ 329-331 (lines=3) @@ | ||
| 326 | if (!empty($this->form['options']['access']['apps']) && !in_array(\App::$cur->name, $this->form['options']['access']['apps'])) { |
|
| 327 | return false; |
|
| 328 | } |
|
| 329 | if (!empty($this->form['options']['access']['groups']) && in_array(\Users\User::$cur->group_id, $this->form['options']['access']['groups'])) { |
|
| 330 | return true; |
|
| 331 | } |
|
| 332 | if ($this->model && !empty($this->form['options']['access']['self']) && \Users\User::$cur->id == $this->model->user_id) { |
|
| 333 | return true; |
|
| 334 | } |
|