app/Http/Controllers/PostController.php
/**
     * Store a newly created resource in storage.
     *
     * @param  \Illuminate\Http\Request  $request
     * @return \Illuminate\Http\Response
     */
Store a newly created resource in storage.
Store a newly created resource in storage .
public function store(StoreUpdatePost $request)
    {
        Post::create($request->all());
        return redirect()
                ->route('posts.index')
                ->with('message', 'Editado com sucesso');
    }
public function store ( StoreUpdatePost $ request ) { Post :: create ( $ request -> all ( ) ) ; return redirect ( ) -> route ( 'posts.index' ) -> with ( 'message' , 'Editado com sucesso' ) ; }
Store a newly created resource in storage.
Store a newly created resource in storage .