I am trying to write an eloquent query that would work as follows:
Support Ticket (one to many with the order)
Query: Filter the support tickets and only show the order if the support ticket is less than 45 days old.
I feel like this would be an adaptation of the whereHas() method in Laravel but I am not sure how to implement a filter or a date search on a relationship like this.
from Newest questions tagged laravel-5 – Stack Overflow https://ift.tt/37r81bt