Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $heads =DB::table('heads');
- ->where('companies.company_id',$company)
- ->where('participants.dni',$dni)
- public function search(Request $request){
- $company=request::get('cliente');//recuperodatosenvporgetopost.
- $dni=request::get('search')
- $heads =DB::table('heads')
- ->join('participants', 'heads.id','=','participants.head_id')
- ->join('companies','company.id','=','companies.id')
- ->select('companies.name as nom_com','participants.firstlastname as ape_pat','participants.secondlastname as ape_mat','participants.name
- as nombre','companies.created_at as fec1','companies.updated_at as fec2')
- ->where('companies.company_id',$company)
- ->where('dni',$dni)
- ->get();
- return Response::json('heads');
- }
Add Comment
Please, Sign In to add comment