Esempio n. 1
0
 public function updateAlumni(Request $request, $id)
 {
     $alumni = Alumni::find($id);
     $input = $request->all();
     $alumni->update($input);
     return response()->json($alumni);
 }
Esempio n. 2
0
 /**
  * Remove the specified Alumni from storage.
  *
  * @param  int  $id
  * @return Response
  */
 public function destroy($id)
 {
     $alumni = Alumni::find($id);
     $alumni->delete();
     Flash::success('Alumni deleted successfully');
     return redirect('/admin/alumni');
 }