How can you combine two collections, one being the collection of parent items together combined with your collection of child items?
I would like something like using the method with
and belongsToMany
,but in this scenario I cannot use both methods correctly because one table is in another schema and the pivot table is in another schema.
Area::with('permissoes')
->where('sistema', '<>', 'S')
->get()