-1
I’m having trouble showing data for two related tables. Controller: public Function index(){
    $tabela = capitulo::orderby('id', 'desc')->paginate();
    
    $tabela1 = documentacao::orderby('id', 'desc')->paginate();
    return view('gestao-documental.index', ['itens' => $tabela, 'itens1' => $tabela1]);
   
}
I can see the Chapter but the documentation does not. I may be wrong for the Return view:
<div class="card shadow mb-4">
<div class="card-body">
 <div class="table-responsive">
<table class="table table-bordered" id="dataTable" width="100%" cellspacing="0">
  <thead>
           @foreach($itens as $item)
                <tr>
                    <th> {{$item->capitulo}} </th>
                    
                    
                </tr>
                  
            </thead>
            @foreach($itens1 as $item1)
            <tbody>
            
            <tr>
                <td> {{$item1->documentacao}} </td>
     
                
            </tr>
            @endforeach     
            </tbody>
            @endforeach  
        </table>
    </div>    
</div>