コード例 #1
0
 /**
  * Display the specified resource.
  *
  * @param  int  $id
  * @return \Illuminate\Http\Response
  */
 public function data()
 {
     $etapas = stage::orderBy('name', 'DESC')->get();
     $actividades = Activity::orderBy('name', 'DESC')->get();
     return response()->json(['etapas' => $etapas, 'actividades' => $actividades]);
 }
コード例 #2
0
 /**
  * Show the form for creating a new resource.
  *
  * @return \Illuminate\Http\Response
  */
 public function allStageAjax()
 {
     $etapas = stage::orderBy('identificador', 'ASC')->get();
     return response()->json($etapas);
 }