32 return View::make(
'account/profile', compact(
'user'))->with(
'location_list', $location_list);
49 $user->first_name = e(Input::get(
'first_name'));
50 $user->last_name = e(Input::get(
'last_name'));
51 $user->website = e(Input::get(
'website'));
52 $user->location_id = e(Input::get(
'location_id'));
53 $user->gravatar = e(Input::get(
'gravatar'));
54 $user->locale = e(Input::get(
'locale'));
56 if (Input::file(
'avatar')) {
57 $image = Input::file(
'avatar');
58 $file_name = $user->first_name.
"-".$user->last_name.
".".$image->getClientOriginalExtension();
59 $path = public_path(
'uploads/avatars/'.$file_name);
60 Image::make($image->getRealPath())->resize(84, 84)->save($path);
61 $user->avatar = $file_name;
64 if (Input::get(
'avatar_delete') == 1 && Input::file(
'avatar') ==
"") {
69 return Redirect::route(
'profile')->with(
'success',
'Account successfully updated');
71 return Redirect::back()->withInput()->withErrors($user->getErrors());
postIndex()
Validates and stores the user's update data.
getIndex()
Returns a view with the user's profile form for editing.
This controller handles all actions related to User Profiles for the Snipe-IT Asset Management applic...