/** * Update the specified resource in storage. * * @param int $id * @return Response */ public function sendRead() { $members = Member::all(); //all data of member collection $inbox_id = HelperController::getPage(); $id = Auth::id(); $author = User::find($id); $inbox = Inbox::find($inbox_id); //find data in Inbox collection $unread = Inbox::where('mail_read', '=', '0')->where('member_id', '=', $id)->get()->count(); //mailbox view return view('vendor/flatAdmin/mailRead', compact(array('members', 'author', 'inbox', 'unread', 'id'))); }