Introduction

I needed a report page, where I wanted to have some information that only admin can view. And, I was in no mood of custom coding. So, the objectives are:

  • Create a new Page with admin role restriction
  • Its menu entry should be created under Reports section so that I dont need to remember its URL

Create a new Admin Page

I used views module for this. Lets have a look at the steps:

  • Goto /admin/structure/views/add
  • Give a name and description
  • Click on Create a page.
  • Give a title, and path. Note: The path can start from anywhere. I gave its path as /admin/stories
  • Under Page Settings in middle of view edit screen
    • Click on Access setting, select Role in Access restrictions, Apply. Select Role as Administrator
    • Click on Menu, and select Reports as shown in below image

Drupal admin page menu option Drupal admin page menu option

Final Setting Drupal admin page menu option

  • Goto /admin/reports/ You will see your menu created here. Now, you can put more blocks in this page. Everything here will be accessible to Administration role only.