So I perform a query to the db and I have a complete array of objects:
@attachments = Job.find(1).attachments
Now that I have an array of o
You can filter using where
Job.includes(:attachments).where(file_type: ["logo", "image"])