app/Http/Controllers/ViewFieldsController.php
/**
     * Store a newly created ViewField in storage.
     *
     * @param  \App\Http\Requests\StoreViewFieldsRequest  $request
     * @return \Illuminate\Http\Response
     */
Store a newly created ViewField in storage.
Store a newly created ViewField in storage .
public function store(StoreViewFieldsRequest $request)
    {
        if (! Gate::allows('view_field_create')) {
            return abort(401);
        }
        $view_field = ViewField::create($request->all());
        return redirect()->route('view_fields.index');
    }
public function store ( StoreViewFieldsRequest $ request ) { if ( ! Gate :: allows ( 'view_field_create' ) ) { return abort ( 401 ) ; } $ view_field = ViewField :: create ( $ request -> all ( ) ) ; return redirect ( ) -> route ( 'view_fields.index' ) ; }
Store a newly created ViewField in storage.
Store a newly created ViewField in storage .