Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
杨树贤
/
ucenter
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
9e8174de
authored
Jan 17, 2024
by
杨树贤
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
绑定邮箱和手机接口
parent
032938a9
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
2 deletions
app/Http/Controllers/Api/UserController.php
routes/api.php
app/Http/Controllers/Api/UserController.php
View file @
9e8174de
...
...
@@ -4,12 +4,13 @@ namespace App\Http\Controllers\Api;
use
App\Http\Controllers\Controller
;
use
App\Http\Services\UserService
;
use
Illuminate\Http\Request
;
class
UserController
extends
Controller
{
//绑定邮箱
public
function
bindEmail
(
\
Request
$request
)
public
function
bindEmail
(
Request
$request
)
{
$ucId
=
$request
->
input
(
'uc_id'
);
if
(
empty
(
$ucId
))
{
...
...
@@ -24,7 +25,7 @@ class UserController extends Controller
}
//绑定手机号
public
function
bindMobile
(
\
Request
$request
)
public
function
bindMobile
(
Request
$request
)
{
$ucId
=
$request
->
input
(
'uc_id'
);
if
(
empty
(
$ucId
))
{
...
...
routes/api.php
View file @
9e8174de
...
...
@@ -6,4 +6,6 @@ use Illuminate\Support\Facades\Route;
Route
::
namespace
(
'Api'
)
->
group
(
function
()
{
Route
::
match
([
"GET"
,
"POST"
],
'/auth/register'
,
'AuthController@register'
);
Route
::
match
([
"GET"
,
"POST"
],
'/auth/login'
,
'AuthController@login'
);
Route
::
match
([
"GET"
,
"POST"
],
'/user/bindEmail'
,
'UserController@bindEmail'
);
Route
::
match
([
"GET"
,
"POST"
],
'/user/bindMobile'
,
'UserController@bindMobile'
);
});
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