Last active
June 7, 2016 12:39
-
-
Save wayanjimmy/c9b8b3b48e7fdba792085fa259eb1c41 to your computer and use it in GitHub Desktop.
Override RouteListCommand
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace App\Console\Commands\Route; | |
use Illuminate\Console\Command; | |
use Illuminate\Foundation\Console\RouteListCommand; | |
use Illuminate\Routing\Router; | |
class BackendRouteListCommand extends RouteListCommand | |
{ | |
/** | |
* The name and signature of the console command. | |
* | |
* @var string | |
*/ | |
protected $name = 'route:list:backend'; | |
/** | |
* The console command description. | |
* | |
* @var string | |
*/ | |
protected $description = 'List all registered backend routes'; | |
/** | |
* Execute the console command. | |
* | |
* @return mixed | |
*/ | |
public function fire() | |
{ | |
$this->routes = $this->router->getRoutes(); | |
parent::fire(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
ganti sama ini gan protected $name = 'route:list:backend';