/** * Show the form for editing the specified resource. * * @param int $id * @return \Illuminate\Http\Response */ public function edit($num_empleado) { $employe = Employe::where('num_empleado', $num_empleado)->first(); $deparments = Deparment::all()->lists('deparment', 'id')->toArray(); asort($deparments); return view('employees.edit')->with('employe', $employe)->with('deparments', $deparments); }