Ejemplo n.º 1
0
 /**
  * Store a newly created resource in storage.
  *
  * @param  \Illuminate\Http\Request  $request
  * @return \Illuminate\Http\Response
  */
 public function store(StorePersonRequest $request)
 {
     $person = new Person($request->all());
     $person->save();
     Session::flash('message', 'Person created');
     return redirect('/person');
 }
Ejemplo n.º 2
0
 public function store(Requests\StorePersonRequest $request)
 {
     $person = new Person();
     $person->first_name = $request->get('first_name');
     $person->last_name = $request->get('last_name');
     $person->parental = $request->get('parental');
     $person->gender = $request->get('gender');
     $person->save();
     flash()->success('Вы добавили ' . $person->first_name);
     return Redirect::route('person.list');
 }
Ejemplo n.º 3
0
 /**
  * Store a newly created resource in storage.
  *
  * @return Response
  */
 public function store(StorePersonRequest $request)
 {
     $this->personService->store($request->all());
     return redirect('persona')->with('message', 'Persona Registrado')->withInput($request->all());
 }