Created
May 6, 2015 20:01
-
-
Save vinicius73/bb94b3b68a370d62d90f to your computer and use it in GitHub Desktop.
Como organizar: Painel e Front no Laravel 5 (Rotas -> Dica extra)
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 | |
## resource ## | |
Route::group(['prefix' => 'painel', 'namespace' => 'Painel'], function() | |
{ | |
Route::resource('posts', 'PostsCtrl'); | |
# Gera | |
# | |
# painel.posts.index # painel.posts.show # painel.posts.create | |
# painel.posts.store # painel.posts.update # painel.posts.destroy | |
}); | |
Route::group(['namespace' => 'Front'], function() | |
{ | |
Route::resource('posts', 'PostsCtrl', ['only' => ['index', 'show']]); | |
# Gera | |
# | |
# posts.index # posts.show | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment