app/Http/Controllers/MateriaController.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(Request $request)
    {
        $materia = $this->request->all();
        Materia::create($materia);
        return redirect()->route('materia.index');
    }
public function store ( Request $ request ) { $ materia = $ this -> request -> all ( ) ; Materia :: create ( $ materia ) ; return redirect ( ) -> route ( 'materia.index' ) ; }
Store a newly created resource in storage.
Store a newly created resource in storage .