From 9511988ddd1d8a70bf1984b740ca0f2f69af5387 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcin=20Miko=C5=82ajczak?= Date: Fri, 1 Jun 2018 17:49:45 +0200 Subject: [PATCH] Follow/Unfollow button in followers/ing lists MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Marcin Mikołajczak --- resources/views/profile/followers.blade.php | 21 ++++++++++++++++++++- resources/views/profile/following.blade.php | 21 ++++++++++++++++++++- 2 files changed, 40 insertions(+), 2 deletions(-) diff --git a/resources/views/profile/followers.blade.php b/resources/views/profile/followers.blade.php index f27d12e5..7bb55867 100644 --- a/resources/views/profile/followers.blade.php +++ b/resources/views/profile/followers.blade.php @@ -56,6 +56,25 @@ {{$user->name}} + @if(Auth::check() && Auth::id() != $user->user_id) + @if($user->followedBy(Auth::user()->profile) == false) + + + + @else + + + + @endif + @endif @endforeach @@ -75,4 +94,4 @@ -@endsection \ No newline at end of file +@endsection diff --git a/resources/views/profile/following.blade.php b/resources/views/profile/following.blade.php index 6e88262b..9f2c1b89 100644 --- a/resources/views/profile/following.blade.php +++ b/resources/views/profile/following.blade.php @@ -56,6 +56,25 @@ {{$user->name}} + @if(Auth::check() && Auth::id() != $user->user_id) + @if($user->followedBy(Auth::user()->profile) == false) + + + + @else + + + + @endif + @endif @endforeach @@ -75,4 +94,4 @@ -@endsection \ No newline at end of file +@endsection