Skip to content

Commit

Permalink
fix permission
Browse files Browse the repository at this point in the history
  • Loading branch information
summerblue committed Oct 25, 2017
1 parent 173b3ba commit 4a14663
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 6 deletions.
2 changes: 1 addition & 1 deletion readme.md
Expand Up @@ -34,7 +34,7 @@ Forked from [FrozenNode/Laravel-Administrator](https://github.com/FrozenNode/Lar
### 1. composer require

```
composer require "summerblue/administrator:^1.0"
composer require "summerblue/administrator:^1.1"
```

### 2. add provider
Expand Down
Expand Up @@ -3,6 +3,7 @@
namespace Frozennode\Administrator;

use Illuminate\Support\Facades\Config;
use Illuminate\Support\Facades\Route;
use Illuminate\Support\ServiceProvider;
use Frozennode\Administrator\DataTable\DataTable;
use Illuminate\Support\Facades\Validator as LValidator;
Expand Down Expand Up @@ -54,7 +55,13 @@ public function register()
{
//include our view composers, and routes to avoid issues with catch-all routes defined by users
include __DIR__.'/../../viewComposers.php';
include __DIR__.'/../../routes.php';

// Load route with web middleware
Route::group([
'middleware' => 'web',
], function () {
$this->loadRoutesFrom(__DIR__.'/../../routes.php');
});

//the admin validator
$this->app->singleton('admin_validator', function ($app) {
Expand Down
8 changes: 4 additions & 4 deletions src/config/administrator.php
Expand Up @@ -21,7 +21,7 @@
*
* @type string
*/
'title' => 'EST 官网管理',
'title' => config('app.name'),

/*
* The path to your model config directory
Expand Down Expand Up @@ -58,7 +58,7 @@
* 'Analytics' => array('E-Commerce' => 'page.ecommerce.analytics'),
* )
*/
'menu' => array(),
'menu' => [],

/*
* The permission option is the highest-level authentication check that lets you define a closure that should return true if the current user
Expand Down Expand Up @@ -104,7 +104,7 @@
*
* @type string
*/
'login_path' => 'auth/login',
'login_path' => 'login',

/*
* The logout path is the path where Administrator will send the user when they click the logout link
Expand Down Expand Up @@ -133,7 +133,7 @@
*
* @type array
*/
'locales' => array(),
'locales' => [],

'custom_routes_file' => app_path('Http/routes/administrator.php'),
);

0 comments on commit 4a14663

Please sign in to comment.