app/Http/Controllers/TagsController.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(TagsRequest $request)
    {
        $tag = new Tag($request->all());
        $tag->slug = Str::slug($request->name);
        $tag->save();
        Flash::success("El Tag <b>$tag->name</b> fue guardado");
        return redirect()->route('tags.index');
    }
public function store ( TagsRequest $ request ) { $ tag = new Tag ( $ request -> all ( ) ) ; $ tag -> slug = Str :: slug ( $ request -> name ) ; $ tag -> save ( ) ; Flash :: success ( " El Tag <b> $ tag -> name </b> fue guardado " ) ; return redirect ( ) -> route ( 'tags.index' ) ; }
Store a newly created resource in storage.
Store a newly created resource in storage .