src/AdminSections/SupportContacts/SupportContactsVoter.php line 10

Open in your IDE?
  1. <?php declare(strict_types=1);
  2. namespace PPAdmin\AdminSections\SupportContacts;
  3. use PlnaPenezenka\PPSDKBundle\Doctrine\Entity\Administrator;
  4. use PlnaPenezenka\PPSDKBundle\Doctrine\Entity\Common\DefaultEntity;
  5. use PlnaPenezenka\PPSDKBundle\Doctrine\Entity\Web;
  6. use PPAdmin\AdminSections\AdminSectionsList;
  7. use PPAdmin\Security\AbstractAdminGridSectionVoter;
  8. class SupportContactsVoter extends AbstractAdminGridSectionVoter
  9. {
  10.     public static function getSectionIdentifier(): string
  11.     {
  12.         return AdminSectionsList::SUPPORT_CONTACTS;
  13.     }
  14.     protected static function getSupportedSectionPermissions(): array
  15.     {
  16.         return [
  17.             self::SECTION_PERMISSION_ACCESS,
  18.             self::SECTION_PERMISSION_LIST,
  19.             self::SECTION_PERMISSION_VIEW_DETAIL,
  20.             self::SECTION_PERMISSION_VIEW_AUDIT,
  21.         ];
  22.     }
  23.     function canCreateSectionRecords(Administrator $adminWeb $web): bool
  24.     {
  25.         return false;
  26.     }
  27.     function canEditRecord(Administrator $adminDefaultEntity $record): bool
  28.     {
  29.         return false;
  30.     }
  31.     function canDeleteRecord(Administrator $adminDefaultEntity $record): bool
  32.     {
  33.         return false;
  34.     }
  35. }