FEATURE #1424: add title photo to list of all pages

This commit is contained in:
Michal Kváček
2016-03-31 22:56:31 +02:00
parent 590e1eeaca
commit 6378d17753
@@ -1,7 +1,12 @@
<div class="row" id="static-page-overview" data-equalizer>
<div class="row" id="static-page-overview" data-equalizer data-equalize-by-row="true">
@forelse($pages as $page)
<div class="columns @if(!isset($tileClass)) large-3 @else {{$tileClass}} @endif">
<div class="page callout" data-equalizer-watch>
@if ($page->title_photo)
<img src="{{config('app.upload_url')}}/{{$page->title_photo}}" alt="" />
@endif
<h4>{{$page->title}}</h4>
<span class="date">{{date('d.m.Y', strtotime($page->created_at))}}</span>
<span class="author">{{$page->author_name}}</span>
@@ -24,22 +29,36 @@
@if($page->is_homepage)
<a class="button tiny disabled"><i class="fa fa-home"></i></a>
@else
<a href="{{route('content.setHomepage', ['id' => $page->id])}}" class="button tiny success has-tip" data-tooltip aria-haspopup="true" title="@lang('admin/contents.setHomepage', ['name' => $page->title])"><i class="fa fa-home"></i></a>
<a href="{{route('content.setHomepage', ['id' => $page->id])}}"
class="button tiny success has-tip" data-tooltip aria-haspopup="true"
title="@lang('admin/contents.setHomepage', ['name' => $page->title])"><i
class="fa fa-home"></i></a>
@endif
<a href="{{route('content.edit', ['id' => $page->id])}}" class="button tiny success has-tip" data-tooltip aria-haspopup="true" title="@lang('admin/contents.edit', ['name' => $page->title])"><i class="fa fa-edit"></i></a>
<a href="{{route('content.edit', ['id' => $page->id])}}" class="button tiny success has-tip"
data-tooltip aria-haspopup="true"
title="@lang('admin/contents.edit', ['name' => $page->title])"><i class="fa fa-edit"></i></a>
@if($page->status == \App\Models\Content::STATUS_DRAFT)
<a href="{{route('content.changeStatus', ['id' => $page->id, 'status' => \App\Models\Content::STATUS_PUBLIC])}}" class="button tiny success confirm has-tip" data-tooltip aria-haspopup="true" title="@lang('admin/contents.makePublic')"><i class="fa fa-eye"></i></a>
<a href="{{route('content.changeStatus', ['id' => $page->id, 'status' => \App\Models\Content::STATUS_PROTECTED])}}" class="button tiny warning confirm has-tip" data-tooltip aria-haspopup="true" title="@lang('admin/contents.makeProtected')"><i class="fa fa-lock"></i></a>
<a href="{{route('content.changeStatus', ['id' => $page->id, 'status' => \App\Models\Content::STATUS_PUBLIC])}}"
class="button tiny success confirm has-tip" data-tooltip aria-haspopup="true"
title="@lang('admin/contents.makePublic')"><i class="fa fa-eye"></i></a>
<a href="{{route('content.changeStatus', ['id' => $page->id, 'status' => \App\Models\Content::STATUS_PROTECTED])}}"
class="button tiny warning confirm has-tip" data-tooltip aria-haspopup="true"
title="@lang('admin/contents.makeProtected')"><i class="fa fa-lock"></i></a>
@else
<a href="{{route('page.content', ['url' => $page->url])}}" target="_blank" class="button tiny secondary has-tip" data-tooltip aria-haspopup="true" title="@lang('admin/contents.viewPage')"><i class="fa fa-desktop"></i></a>
<a href="{{route('content.changeStatus', ['id' => $page->id, 'status' => \App\Models\Content::STATUS_DRAFT])}}" class="button tiny warning confirm has-tip" data-tooltip aria-haspopup="true" title="@lang('admin/contents.makeDraft')"><i class="fa fa-eye-slash"></i></a>
<a href="{{route('page.content', ['url' => $page->url])}}" target="_blank"
class="button tiny secondary has-tip" data-tooltip aria-haspopup="true"
title="@lang('admin/contents.viewPage')"><i class="fa fa-desktop"></i></a>
<a href="{{route('content.changeStatus', ['id' => $page->id, 'status' => \App\Models\Content::STATUS_DRAFT])}}"
class="button tiny warning confirm has-tip" data-tooltip aria-haspopup="true"
title="@lang('admin/contents.makeDraft')"><i class="fa fa-eye-slash"></i></a>
@endif
<a href="{{route('content.delete', ['id' => $page->id])}}" class="button tiny alert confirm has-tip" data-tooltip aria-haspopup="true" title="@lang('admin/contents.deletePage')"><i class="fa fa-remove"></i></a>
<a href="{{route('content.delete', ['id' => $page->id])}}"
class="button tiny alert confirm has-tip" data-tooltip aria-haspopup="true"
title="@lang('admin/contents.deletePage')"><i class="fa fa-remove"></i></a>
</p>
</div>
</div>
@empty