@extends('pages.profile_page') @section('content')
@if(session()->has('success-profile'))
{{ session()->get('success-profile') }}
@endif
{!! Form::model($user, ['method' => 'PATCH', 'action' => ['App\Http\Controllers\UserController@update', $user->id], 'files' => true]) !!}
picture == '/storage/images/no-picture') src="{{$user->random}}" @else src="{{$user->picture}}" @endif alt="Picture not set yet" title="Picture not set yet">
{!! Form::label('name', 'Name:', ['class' => 'mb-2']) !!} {!! Form::text('name', null, ['class' => 'form-control']) !!}
{!! Form::label('email', 'Email address:', ['class' => 'mb-2']) !!} {!! Form::text('email', null, ['class' => 'form-control']) !!}
{!! Form::label('password', 'Password:') !!} {!! Form::password('password',['class' => 'form-control']) !!}
{!! Form::label('picture', 'Picture:', ['class' => 'mb-2']) !!} {!! Form::file('picture', null, ['class' => 'form-control']) !!}
@if (auth()->user()->admin == 'true' || auth()->user()->admin == 'TRUE') {!! Form::label('about', 'About:', ['class' => 'mb-2']) !!} {{ Form::textarea('about', null, ['class' => 'form-control', 'rows' => 1, 'name' => 'about', 'id' => 'myeditorinstance', ]) }} @endif
{!! Form::submit('Save', ['class' => 'btn btn-primary button-hover']) !!}
{!! Form::close() !!}
@endsection