示例#1
0
 /**
  * Update a record
  * @param  mixed $id
  * @return Response
  */
 public function update($id)
 {
     // Later, make sure resource exist and user is authorized
     $this->validate($this->request, ['title' => 'required|max:255', 'content' => 'required']);
     $data = ['title' => $this->request->input('title'), 'content' => $this->request->input('content')];
     $this->noteRepository->update($data, $id);
 }