Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
Toggle navigation
This project
Loading...
Sign in
hfpp2012
/
laravel-blog
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 2ed6348d
authored
Aug 05, 2017
by
hfpp2012 yinsigan
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
修改user mdoel
1 parent
806a3d84
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
0 deletions
app/User.php
app/User.php
View file @
2ed6348
...
...
@@ -26,4 +26,14 @@ class User extends Authenticatable
protected
$hidden
=
[
'password'
,
'remember_token'
,
];
public
function
setNameAttribute
(
$value
)
{
$this
->
attributes
[
'name'
]
=
ucfirst
(
$value
);
}
public
function
setPasswordAttribute
(
$value
)
{
$this
->
attributes
[
'password'
]
=
bcrypt
(
$value
);
}
}
Write
Preview
Markdown
is supported
Attach a file
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 post a comment