| @@ 143-152 (lines=10) @@ | ||
| 140 | * |
|
| 141 | * @return boolean |
|
| 142 | */ |
|
| 143 | public function canView($member = null) |
|
| 144 | { |
|
| 145 | if ($this->hasMethod('getPage')) { |
|
| 146 | if ($page = $this->getPage()) { |
|
| 147 | return $page->canView($member); |
|
| 148 | } |
|
| 149 | } |
|
| 150 | ||
| 151 | return (Permission::check('CMS_ACCESS', 'any', $member)) ? true : null; |
|
| 152 | } |
|
| 153 | ||
| 154 | /** |
|
| 155 | * Basic permissions, defaults to page perms where possible. |
|
| @@ 161-170 (lines=10) @@ | ||
| 158 | * |
|
| 159 | * @return boolean |
|
| 160 | */ |
|
| 161 | public function canEdit($member = null) |
|
| 162 | { |
|
| 163 | if ($this->hasMethod('getPage')) { |
|
| 164 | if ($page = $this->getPage()) { |
|
| 165 | return $page->canEdit($member); |
|
| 166 | } |
|
| 167 | } |
|
| 168 | ||
| 169 | return (Permission::check('CMS_ACCESS', 'any', $member)) ? true : null; |
|
| 170 | } |
|
| 171 | ||
| 172 | /** |
|
| 173 | * Basic permissions, defaults to page perms where possible. |
|
| @@ 183-192 (lines=10) @@ | ||
| 180 | * |
|
| 181 | * @return boolean |
|
| 182 | */ |
|
| 183 | public function canDelete($member = null) |
|
| 184 | { |
|
| 185 | if ($this->hasMethod('getPage')) { |
|
| 186 | if ($page = $this->getPage()) { |
|
| 187 | return $page->canArchive($member); |
|
| 188 | } |
|
| 189 | } |
|
| 190 | ||
| 191 | return (Permission::check('CMS_ACCESS', 'any', $member)) ? true : null; |
|
| 192 | } |
|
| 193 | ||
| 194 | /** |
|
| 195 | * Basic permissions, defaults to page perms where possible. |
|