Fragment gemist bijna af
This commit is contained in:
26
website/resources/views/radioscheduleweek.blade.php
Normal file
26
website/resources/views/radioscheduleweek.blade.php
Normal file
@@ -0,0 +1,26 @@
|
||||
@php($date = null)@php($now = new \DateTime("now"))
|
||||
@foreach($schedule as $item)
|
||||
@if(($formattedDate = Formatter::fullDate($item['starttime'], 'W d m')) != $date)
|
||||
@php($date = $formattedDate)
|
||||
@if($date != null) </table> @endif
|
||||
<h2>{{$formattedDate}}</h2>
|
||||
<table class="table table-hover">
|
||||
@endif
|
||||
@php($isCurrent = ($now >= $item['starttime']) && ($now <= $item['endtime']))
|
||||
@php($class =( $item['program']->priority < 2 ? 'bg-primary'
|
||||
:( $item['program']->nonstop || $item['program']->rerun ? 'text-muted'
|
||||
:( $isCurrent ? 'bg-info active text-primary'
|
||||
:( ''
|
||||
)))))
|
||||
<tr @if($class) class="{{$class}}" @endif>
|
||||
<td class="time"><p>{{$item['starttime']->format('H:i')}} – {{$item['endtime']->format('H:i')}} uur</p></td>
|
||||
<td class="title">
|
||||
<p><a title="{{$item['program']->name}}" href="programma{{$item['program']->url}}">{{$item['program']->name}}
|
||||
@if($isCurrent) <span class="bg-primary current-marker">Nu op NH Gooi</span> @endif
|
||||
</a><p>
|
||||
<p>{{Formatter::excerpt(strip_tags($item['program']->description), 200)}}</p>
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</table>
|
||||
|
||||
Reference in New Issue
Block a user