/** * Update the specified resource in storage. * * @param int $id * @return Response */ public function update($id) { echo "i m here"; $bed = Beds::findOrFail($id); $validator = Validator::make($data = Input::all(), Beds::$rules); if ($validator->fails()) { return Redirect::back()->withErrors($validator)->withInput(); } $bed->update($data); return Redirect::route('adminipd.index'); }