lundi 19 avril 2021

i try to show details from intermediate table through id rapport but the result is empty

public function show(RapportMP $rapportMP){
       $ligne = DB::table('ligne_rapport_m_p_s')
        ->join('rapport_m_p_s', 'ligne_rapport_m_p_s.rapportMP_id', '=', 'rapport_m_p_s.id')
        ->get()
        ->toArray();
        echo'<pre>';
        print_r($ligne) ;
       
       
}

i tried to join but nothing work the result is empty .can somoene be able to explain how can i show details of ligne_rapport through id rapport?




from Newest questions tagged laravel-5 - Stack Overflow https://ift.tt/3szlWTQ
via IFTTT

Aucun commentaire:

Enregistrer un commentaire