Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
syncEnrollments
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Yeray Santana Hualde
syncEnrollments
Commits
9f81d4df
Commit
9f81d4df
authored
Sep 28, 2014
by
Taylor Otwell
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Simplify things.
parent
cd37f40b
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
50 additions
and
72 deletions
+50
-72
RouteServiceProvider.php
app/Providers/RouteServiceProvider.php
+5
-7
paths.php
bootstrap/paths.php
+45
-26
namespaces.php
config/namespaces.php
+0
-39
No files found.
app/Providers/RouteServiceProvider.php
View file @
9f81d4df
...
@@ -17,9 +17,7 @@ class RouteServiceProvider extends ServiceProvider {
...
@@ -17,9 +17,7 @@ class RouteServiceProvider extends ServiceProvider {
*/
*/
public
function
before
(
Router
$router
,
UrlGenerator
$url
)
public
function
before
(
Router
$router
,
UrlGenerator
$url
)
{
{
$url
->
setRootControllerNamespace
(
$url
->
setRootControllerNamespace
(
'App\Http\Controllers'
);
trim
(
config
(
'namespaces.controllers'
),
'\\'
)
);
}
}
/**
/**
...
@@ -28,13 +26,13 @@ class RouteServiceProvider extends ServiceProvider {
...
@@ -28,13 +26,13 @@ class RouteServiceProvider extends ServiceProvider {
* @return void
* @return void
*/
*/
public
function
map
()
public
function
map
()
{
$this
->
app
->
booted
(
function
()
{
{
// Once the application has booted, we will include the default routes
// Once the application has booted, we will include the default routes
// file. This "namespace" helper will load the routes file within a
// file. This "namespace" helper will load the routes file within a
// route group which automatically sets the controller namespace.
// route group which automatically sets the controller namespace.
$this
->
namespaced
(
function
(
Router
$router
)
$this
->
app
->
booted
(
function
()
{
$this
->
namespaced
(
'App\Http\Controllers'
,
function
(
Router
$router
)
{
{
require
app_path
()
.
'/Http/routes.php'
;
require
app_path
()
.
'/Http/routes.php'
;
});
});
...
...
bootstrap/paths.php
View file @
9f81d4df
...
@@ -17,61 +17,80 @@ return [
...
@@ -17,61 +17,80 @@ return [
/*
/*
|--------------------------------------------------------------------------
|--------------------------------------------------------------------------
|
Public
Path
|
Base
Path
|--------------------------------------------------------------------------
|--------------------------------------------------------------------------
|
|
| The
public path contains the assets for your web application, such as
| The
base path is the root of the Laravel installation. Most likely you
|
your JavaScript and CSS files, and also contains the primary entry
|
will not need to change this value. But, if for some wild reason it
|
point for web requests into these applications from the outside
.
|
is necessary you will do so here, just proceed with some caution
.
|
|
*/
*/
'
public'
=>
__DIR__
.
'/../public
'
,
'
base'
=>
__DIR__
.
'/..
'
,
/*
/*
|--------------------------------------------------------------------------
|--------------------------------------------------------------------------
|
Base
Path
|
Configuration
Path
|--------------------------------------------------------------------------
|--------------------------------------------------------------------------
|
|
| Th
e base path is the root of the Laravel installation. Most likely you
| Th
is path is used by the configuration loader to load the application
|
will not need to change this value. But, if for some wild reason it
|
configuration files. In general, you should'nt need to change this
|
is necessary you will do so here, just proceed with some caution
.
|
value; however, you can theoretically change the path from here
.
|
|
*/
*/
'
base'
=>
__DIR__
.
'/..
'
,
'
config'
=>
__DIR__
.
'/../config
'
,
/*
/*
|--------------------------------------------------------------------------
|--------------------------------------------------------------------------
|
Storag
e Path
|
Databas
e Path
|--------------------------------------------------------------------------
|--------------------------------------------------------------------------
|
|
| Th
e storage path is used by Laravel to store cached Blade views, logs
| Th
is path is used by the migration generator and migration runner to
|
and other pieces of information. You may modify the path here when
|
know where to place your fresh database migration classes. You're
|
you want to change the location of this directory for your apps
.
|
free to modify the path but you probably will not ever need to
.
|
|
*/
*/
'
storage'
=>
__DIR__
.
'/../storag
e'
,
'
database'
=>
__DIR__
.
'/../databas
e'
,
/*
/*
|--------------------------------------------------------------------------
|--------------------------------------------------------------------------
|
Generator Paths
|
Language Path
|--------------------------------------------------------------------------
|--------------------------------------------------------------------------
|
|
| Th
ese paths are used by the various class generators and other pieces
| Th
is path is used by the language file loader to load your application
|
of the framework that need to determine where to store these type
s
|
language files. The purpose of these files is to store your string
s
|
of classes. Of course, they may be changed to any path you wish
.
|
that are translated into other languages for views, e-mails, etc
.
|
|
*/
*/
'console'
=>
__DIR__
.
'/../app/Console'
,
'config'
=>
__DIR__
.
'/../config'
,
'controllers'
=>
__DIR__
.
'/../app/Http/Controllers'
,
'database'
=>
__DIR__
.
'/../database'
,
'filters'
=>
__DIR__
.
'/../app/Http/Filters'
,
'lang'
=>
__DIR__
.
'/../resources/lang'
,
'lang'
=>
__DIR__
.
'/../resources/lang'
,
'providers'
=>
__DIR__
.
'/../app/Providers'
,
'requests'
=>
__DIR__
.
'/../app/Http/Requests'
,
/*
|--------------------------------------------------------------------------
| Public Path
|--------------------------------------------------------------------------
|
| The public path contains the assets for your web application, such as
| your JavaScript and CSS files, and also contains the primary entry
| point for web requests into these applications from the outside.
|
*/
'public'
=>
__DIR__
.
'/../public'
,
/*
|--------------------------------------------------------------------------
| Storage Path
|--------------------------------------------------------------------------
|
| The storage path is used by Laravel to store cached Blade views, logs
| and other pieces of information. You may modify the path here when
| you want to change the location of this directory for your apps.
|
*/
'storage'
=>
__DIR__
.
'/../storage'
,
];
];
config/namespaces.php
deleted
100644 → 0
View file @
cd37f40b
<?php
return
[
/*
|--------------------------------------------------------------------------
| Application Namespace
|--------------------------------------------------------------------------
|
| This is the root namespace used by the various Laravel generator tasks
| that are able to build controllers, console commands and many other
| classes for you. You may set the name via the "app:name" command.
|
*/
'root'
=>
'App\\'
,
/*
|--------------------------------------------------------------------------
| Generator Namespaces
|--------------------------------------------------------------------------
|
| These namespaces are utilized by the various class generator Artisan
| commands. You are free to change them to whatever you wish or not
| at all. The "app:name" command is the easiest way to set these.
|
*/
'console'
=>
'App\Console\\'
,
'controllers'
=>
'App\Http\Controllers\\'
,
'filters'
=>
'App\Http\Filters\\'
,
'providers'
=>
'App\Providers\\'
,
'requests'
=>
'App\Http\Requests\\'
,
];
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment