public function index() { // Get only the stories that have been published // $stories = Story::with('tags')->where('published', '=', '1')->get(); // Get all the stories $stories = Story::with('tags')->get(); return view('stories', ['stories' => $stories]); }
public function index() { $stories = Story::with('tags')->get(); return view('stories', ['stories' => $stories]); }
/** * get all the trashes of mine * @return [json] [description] */ public function getTrashesMine() { $trashes = Story::with('user')->where('user_id', Auth::user()->id)->where('status', 'trash')->get(); return $trashes; }
public function index() { $stories = Story::with('tags')->get(); return view('stories', ['stories' => $stories]); //return "Hello from StoryController"; }