Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Cong.Zhao
/
musician-api.hikoon.com
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
Commit
eab6d6c0
...
eab6d6c000a20e25eeb0162e42d1ee6ec3648245
authored
2021-06-29 13:33:12 +0800
by
lemon
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
*
1 parent
025c90db
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
3 deletions
app/Http/Controllers/Admin/MusicianWithdrawController.php
app/Http/Middleware/AuthIdentifier.php
routes/admin.php
app/Http/Controllers/Admin/MusicianWithdrawController.php
View file @
eab6d6c
...
...
@@ -36,4 +36,5 @@ class MusicianWithdrawController extends Controller
{
return
$this
->
musicianWithdrawService
->
withdraw
();
}
}
...
...
app/Http/Middleware/AuthIdentifier.php
View file @
eab6d6c
...
...
@@ -15,6 +15,10 @@ use Illuminate\Http\Request;
*/
class
AuthIdentifier
{
protected
$auth
=
[
'api'
];
/**
* Handle an incoming request.
*
...
...
@@ -24,6 +28,9 @@ class AuthIdentifier
*/
public
function
handle
(
Request
$request
,
Closure
$next
)
{
$prefix
=
current
(
explode
(
'/'
,
$request
->
path
()));
if
(
!
in_array
(
$prefix
,
$this
->
auth
))
goto
AUTH
;
$identifier
=
$request
->
header
(
'identifier'
);
if
(
env
(
'APP_ENV'
)
==
'local'
&&
empty
(
$identifier
))
{
...
...
@@ -45,6 +52,8 @@ class AuthIdentifier
'stakeholder_ids'
=>
$stakeholder_ids
,
]);
AUTH
:
return
$next
(
$request
);
}
}
...
...
routes/admin.php
View file @
eab6d6c
...
...
@@ -13,9 +13,6 @@ use Illuminate\Support\Facades\Route;
|
*/
Route
::
group
([],
function
(){
Route
::
get
(
'musician/xxx1'
,
'MusicianWithdrawController@withdraw'
);
//提现审核通过
Route
::
post
(
'musician/withdraw'
,
'MusicianWithdrawController@withdraw'
);
});
...
...
Please
register
or
sign in
to post a comment