app/Http/Controllers/PackpubsController.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)
    {
        $pack = Pack::create([
            'libelle_pack'      => $request['libelle_pack'],
            'montant'           => $request['montant'],
            'jour'           => $request['jour']
        ]);
        if($pack){
            return redirect()->route('packpubs.index');
        }
    }
public function store ( Request $ request ) { $ pack = Pack :: create ( [ 'libelle_pack' => $ request [ 'libelle_pack' ] , 'montant' => $ request [ 'montant' ] , 'jour' => $ request [ 'jour' ] ] ) ; if ( $ pack ) { return redirect ( ) -> route ( 'packpubs.index' ) ; } }
Store a newly created resource in storage.
Store a newly created resource in storage .