Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
U
UserAdminV2
Overview
Overview
Details
Activity
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
庄欣
UserAdminV2
Commits
8f66f4b6
Commit
8f66f4b6
authored
Jul 24, 2016
by
Taylor Otwell
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Tweak default files.
parent
eedac025
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
6 deletions
+7
-6
app/Providers/RouteServiceProvider.php
+3
-1
routes/api.php
+4
-5
No files found.
app/Providers/RouteServiceProvider.php
View file @
8f66f4b6
...
@@ -68,7 +68,9 @@ class RouteServiceProvider extends ServiceProvider
...
@@ -68,7 +68,9 @@ class RouteServiceProvider extends ServiceProvider
protected
function
mapApiRoutes
()
protected
function
mapApiRoutes
()
{
{
Route
::
group
([
Route
::
group
([
'namespace'
=>
$this
->
namespace
,
'middleware'
=>
'api'
,
'middleware'
=>
[
'api'
,
'auth:api'
],
'namespace'
=>
$this
->
namespace
,
'prefix'
=>
'api'
,
],
function
(
$router
)
{
],
function
(
$router
)
{
require
base_path
(
'routes/api.php'
);
require
base_path
(
'routes/api.php'
);
});
});
...
...
routes/api.php
View file @
8f66f4b6
<?php
<?php
use
Illuminate\Http\Request
;
/*
/*
|--------------------------------------------------------------------------
|--------------------------------------------------------------------------
| API Routes
| API Routes
...
@@ -11,9 +13,6 @@
...
@@ -11,9 +13,6 @@
|
|
*/
*/
Route
::
group
([
Route
::
get
(
'/user'
,
function
(
Request
$request
)
{
'prefix'
=>
'api'
,
return
$request
->
user
();
'middleware'
=>
'auth:api'
,
],
function
()
{
//
});
});
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