v1.5.24 Added archive function
This commit is contained in:
@@ -88,8 +88,6 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@else
|
||||
<p class="text-center mb-auto">{{__('msg.dereringenaktiviteter')}}!</p>
|
||||
@endif
|
||||
@endforeach
|
||||
@else
|
||||
|
||||
@@ -128,6 +128,7 @@
|
||||
@foreach($news as $new)
|
||||
<!--Code to list events-->
|
||||
@if($new->type == 'News')<!--Code that prints news-->
|
||||
@if(\Carbon\Carbon::now() < date("Y-m-d H:i", strtotime($new->news_expiration_date)))
|
||||
<div class="card">
|
||||
<div class="img"><img src="{{URL::asset('/images/icons/news.svg')}}" alt="News:"></div>
|
||||
<div class="title">
|
||||
@@ -160,7 +161,9 @@
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
@elseif($new->type == 'Activity')<!--Code that prints events-->
|
||||
@if(\Carbon\Carbon::now() < date("Y-m-d H:i", strtotime($new->news_expiration_date)))
|
||||
<div class="card">
|
||||
<div class="img"><a href="{{ route('events.index') }}"><img src="{{URL::asset('/images/icons/Aktiviteter.svg')}}" alt="Aktiviteter:"></a></div>
|
||||
<div class="title">{{ $new->subname }}
|
||||
@@ -197,7 +200,9 @@
|
||||
</div>
|
||||
@endif
|
||||
</div>
|
||||
@endif
|
||||
@elseif($new->type == 'Guide')<!--Code that prints guides-->
|
||||
@if(\Carbon\Carbon::now() < date("Y-m-d H:i", strtotime($new->news_expiration_date)))
|
||||
<div class="card">
|
||||
<div class="img"><a href="{{ route('guides.index') }}"><img src="{{URL::asset('/images/icons/Vejledninger.svg')}}" alt="Vejledninger:"></a></div>
|
||||
<div class="title">{{ $new->subname }}
|
||||
@@ -217,10 +222,12 @@
|
||||
@endif {{-- Else if it's a menu or news, then don't show a button at bottom --}}
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
<!---->
|
||||
@elseif($new->type == 'MultipleEvent')
|
||||
@if(\Carbon\Carbon::now() < date("Y-m-d H:i:s", strtotime($new->news_expiration_date)))
|
||||
<div class="card">
|
||||
<div class="img"><a href="{{ route('multiple-events.index') }}"><img src="{{URL::asset('/images/icons/Aktiviteter.svg')}}" alt="aktiviteter:"></a></div>
|
||||
<div class="img"><a href="{{ route('multiple-events.index') }}"><img src="{{URL::asset('/images/icons/calendar2.svg')}}" alt="aktiviteter:"></a></div>
|
||||
<div class="title">Ugentlig aktiviteter for uge {{ $new->subname }}
|
||||
<span class="createdat">{{__('msg.opret')}}{{ date('Y-m-d H:i:s', strtotime($new->created_at))}}</span>
|
||||
</div>
|
||||
@@ -236,10 +243,8 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@endif
|
||||
@endif
|
||||
|
||||
|
||||
|
||||
@endforeach
|
||||
@if(count(\App\News::query()->orderBy("created_at", "desc")->get()) == 0)
|
||||
<p class="text-center">{{__('msg.ingennyheder')}}</p>
|
||||
|
||||
Reference in New Issue
Block a user