示例#1
0
 public function load()
 {
     # change 'guests' to your user roles
     if (ACL::isAllowed('user', Route::getControllerName(), Route::getActionName()) == false) {
         throw new AccessNotAllowedException('You are not allowed to access this page');
     }
 }
示例#2
0
<?php

use Bootstrap\Facades\Route;
Route::add('/acme/test', ['module' => 'acme', 'controller' => 'Acme', 'action' => 'test']);