1 | <?php |
||
10 | class StandardPermissions extends DataExtension implements PermissionProvider |
||
|
|||
11 | { |
||
12 | |||
13 | /** |
||
14 | * Can the user publish this? |
||
15 | */ |
||
16 | public function canPublish($member = false) |
||
20 | |||
21 | /** |
||
22 | * Can the user unpublish this? |
||
23 | */ |
||
24 | public function canUnpublish($member = false) |
||
28 | |||
29 | /** |
||
30 | * Can the user archive this? |
||
31 | */ |
||
32 | public function canArchive($member = false) |
||
36 | |||
37 | public function canView($member = false) |
||
53 | |||
54 | /** |
||
55 | * Get a complete list of all the permissions this class uses. |
||
56 | */ |
||
57 | public function providePermissions() |
||
81 | } |
||
82 |
You can fix this by adding a namespace to your class:
When choosing a vendor namespace, try to pick something that is not too generic to avoid conflicts with other libraries.