| Conditions | 1 |
| Paths | 1 |
| Total Lines | 23 |
| Code Lines | 14 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 17 |
| CRAP Score | 1.0002 |
| Changes | 3 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php namespace Arcanesoft\Auth\Http\Routes\Foundation; |
||
| 24 | 24 | public function map(Registrar $router) |
|
| 25 | { |
||
| 26 | 24 | parent::map($router); |
|
| 27 | |||
| 28 | 24 | $this->group([ |
|
| 29 | 24 | 'prefix' => 'permissions', |
|
| 30 | 18 | 'as' => 'permissions.', |
|
| 31 | ], function () { |
||
| 32 | 24 | $this->get('/', [ |
|
| 33 | 24 | 'as' => 'index', // auth::foundation.permissions.index |
|
| 34 | 18 | 'uses' => 'PermissionsController@index', |
|
| 35 | 18 | ]); |
|
| 36 | |||
| 37 | 24 | $this->get('{permission_id}/show', [ |
|
| 38 | 24 | 'as' => 'show', // auth::foundation.permissions.show |
|
| 39 | 18 | 'uses' => 'PermissionsController@show', |
|
| 40 | 18 | ]); |
|
| 41 | 24 | }); |
|
| 42 | |||
| 43 | 24 | $router->bind('permission_id', function($hashedId) { |
|
| 44 | return Permission::firstHashedOrFail($hashedId); |
||
| 45 | 24 | }); |
|
| 46 | 24 | } |
|
| 47 | } |
||
| 48 |