Beispiel #1
0
 /**
  * Update the specified resource in storage.
  *
  * @param  Request  $request
  * @param  int  $id
  * @return Response
  */
 public function update(ListFormRequest $request, $id)
 {
     $list = Todolist::find($id);
     $list->update(['name' => $request->get('name'), 'description' => $request->get('description')]);
     return \Redirect::route('lists.edit', [$list->id])->with('message', 'List has been Updated');
 }
Beispiel #2
0
 /**
  * Update the specified resource in storage.
  *
  * @param  \Illuminate\Http\Request  $request
  * @param  int  $id
  * @return \Illuminate\Http\Response
  */
 public function update(ListFormRequest $request, $id)
 {
     $list = Todolist::findOrFail($id);
     $list->update(['name' => $request->get('name'), 'description' => $request->get('description')]);
     return \Redirect::route('viewlist', array($list->id))->with('message', 'Your list has been updated');
 }
 /**
  * Update the specified resource in storage.
  *
  * @param  \Illuminate\Http\Request  $request
  * @param  int  $id
  * @return \Illuminate\Http\Response
  */
 public function update($id, ListFormRequest $request)
 {
     $list = Giftlist::find($id);
     $list->update(['name' => $request->get('name'), 'description' => $request->get('description')]);
     return \Redirect::route('lists.edit', array($list->id))->with('message', "Your list has been updated.");
 }