panel.page.read

Permission to access/read a page in the Panel

Target Data

$this->target()->page()

You can deny access to certain pages entirely. They will be hidden from all page lists and the user cannot access any of its features.

Example

<?php

// site/roles/editor.php
return [
  'name'        => 'Editor',
  'default'     => false,
  'permissions' => [
    '*'               => true,
    'panel.page.read' => function() {
      return $this->target()->page()->template() !== 'secret';
    }
  ]
];