Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
projet-cdaw
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
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
Quentin Vrel
projet-cdaw
Commits
8b249049
Commit
8b249049
authored
Dec 03, 2020
by
Zohten
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
push all user public cara
parent
9eb39508
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
1 deletion
+12
-1
LoginController.class.php
BackEnd/src/controller/LoginController.class.php
+8
-1
User.class.php
BackEnd/src/model/User.class.php
+4
-0
No files found.
BackEnd/src/controller/LoginController.class.php
View file @
8b249049
...
...
@@ -54,7 +54,14 @@ class LoginController extends Controller
$jwt
=
JWT
::
encode
(
$token
,
JWT_BACKEND_KEY
);
$jsonResult
=
json_encode
(
array
(
"jwt_token"
=>
$jwt
"jwt_token"
=>
$jwt
,
"id_user"
=>
$user
->
id
(),
"id_role"
=>
$user
->
role
(),
"login"
=>
$user
->
login
(),
"avatar"
=>
$user
->
avatar
(),
"lastname"
=>
$user
->
lastname
(),
"firstname"
=>
$user
->
firstname
(),
"mail"
=>
$user
->
email
()
)
);
...
...
BackEnd/src/model/User.class.php
View file @
8b249049
...
...
@@ -55,6 +55,10 @@ class User extends Model
{
return
trim
(
$this
->
ID_ROLE
);
}
public
function
login
()
{
return
trim
(
$this
->
LOGIN
);
}
public
function
password
()
{
return
trim
(
$this
->
PASWORD
);
...
...
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