Skip to content

Commit

Permalink
Merge pull request #40 from andes2912/feature/website-frontend
Browse files Browse the repository at this point in the history
Imprve frontend content Guru
  • Loading branch information
andes2912 authored Mar 27, 2022
2 parents c550e99 + 718815a commit 2099445
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions app/Http/Controllers/Frontend/IndexController.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
use App\Models\Jurusan;
use App\Models\KategoriBerita;
use App\Models\Kegiatan;
use App\Models\Pengajar;
use App\Models\User;
use App\Models\Video;

class IndexController extends Controller
Expand All @@ -34,7 +34,7 @@ public function index()
$video = Video::where('is_active','0')->first();

// Pengajar
$pengajar = Pengajar::with('user')->where('is_active','0')->get();
$pengajar = User::with('userDetail')->where('status','Aktif')->where('role','Guru')->get();

// Berita
$berita = Berita::where('is_active','0')->orderBy('created_at','desc')->get();
Expand Down
8 changes: 4 additions & 4 deletions resources/views/frontend/content/guru.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@
<div class="single-item">
<div class="lecturers1-item-wrapper">
<div class="lecturers-img-wrapper">
<a href="#"><img class="img-responsive" src="{{asset('storage/images/profile/' .$pengajars->user->foto_profile)}}" alt="team"></a>
<a href="#"><img class="img-responsive" src="{{asset('storage/images/profile/' .$pengajars->foto_profile)}}" alt="team"></a>
</div>
<div class="lecturers-content-wrapper">
<h3 class="item-title"><a href="#">{{$pengajars->user->name}}</a></h3>
<span class="item-designation">{{$pengajars->mengajar}}</span>
<h3 class="item-title"><a href="#">{{$pengajars->name}}</a></h3>
<span class="item-designation">{{$pengajars->userDetail->mengajar}}</span>
<ul class="lecturers-social">
<li><a href="{{$pengajars->website}}" target="_blank"><i class="fa fa-globe" aria-hidden="true"></i></a></li>
<li><a href="{{$pengajars->userDetail->website}}" target="_blank"><i class="fa fa-globe" aria-hidden="true"></i></a></li>
<li><a href="mailto:{{$pengajars->email}}"><i class="fa fa-envelope-o" aria-hidden="true"></i></a></li>
<li><a href="{{'https://www.linkedin.com/in',$pengajars->linkedln}}" target="_blank"><i class="fa fa-linkedin" aria-hidden="true"></i></a></li>
<li><a href="{{'https://www.twitter.com/',$pengajars->twitter}}" target="_blank"><i class="fa fa-twitter" aria-hidden="true"></i></a></li>
Expand Down

0 comments on commit 2099445

Please sign in to comment.