Permet la mise à jour du profil

La mise à jour de l'avatar fonctionne à moitié
Pour #12
This commit is contained in:
2020-03-17 17:33:04 +01:00
parent b54b9959cf
commit f97c6a56ec
10 changed files with 745 additions and 22 deletions

View File

@@ -55,15 +55,22 @@
</div>
<div class="dropdown">
<a href="#" class="nav-link pr-0 leading-none" data-toggle="dropdown">
<span class="avatar">{{ substr(Auth::user()->name, 0, 1) }}</span>
@php($avatar = Auth::user()->getAvatar())
<span class="avatar">
@if($avatar !== '')
<img src="{{ Auth::user()->getAvatar() }}"/>
@else
{{ substr(Auth::user()->name, 0, 1) }}
@endif
</span>
<span class="ml-2 d-none d-lg-block">
<span class="text-default">{{ Auth::user()->name }}</span>
<small class="text-muted d-block mt-1"></small>
</span>
</a>
<div class="dropdown-menu dropdown-menu-right dropdown-menu-arrow">
<a class="dropdown-item" href="#">
<i class="dropdown-icon fe fe-user"></i> Profile
<a class="dropdown-item" href="{{ route('user.index') }}">
<i class="dropdown-icon fe fe-user"></i> {{ __('Profile') }}
</a>
<a class="dropdown-item" href="#">
<i class="dropdown-icon fe fe-settings"></i> Settings