I am printing the notifications for a Model in Laravel 5:
@foreach ($booking->notifications as $notification)
<div class="message">
<div class="myMessage">
<p>{{ $notification->data[0])}}</p>
</div>
</div>
@endforeach
These notifications are being printed in descending order, is there a way I can change this so they print in ascending order?
The Laravel documentation states:
By default, notifications will be sorted by the created_at timestamp
It's worth mentioning that there are multiple Notification classes that have been used with this model so I'm not sure if that affects the sorting behavior?