error('Commentaire : Billet non trouvé'); return view('errors.unavailable'); } catch (\Illuminate\Database\QueryException $e) { Log::channel('projectError')->error('Erreur accès base de données'); return view('errors.dberror'); } return view('vCommenter', compact('idBillet', 'billet')); } /** * Store a newly created resource in storage. */ public function store(StoreCommentaireRequest $request) { try { Commentaire::create($request->all()); } catch (\Illuminate\Database\QueryException $e) { Log::channel('projectError')->error('Insertion en base de données impossible'); return view('errors.dberror'); } Log::channel('projectInfo')->info('Commentaire ajouté par : '.$request->ip()); return view('vConfirmStore'); } /** * Display the specified resource. */ public function show(Commentaire $commentaire) { // } /** * Show the form for editing the specified resource. */ public function edit(Commentaire $commentaire) { // } /** * Update the specified resource in storage. */ public function update(UpdateCommentaireRequest $request, Commentaire $commentaire) { // } /** * Remove the specified resource from storage. */ public function destroy(Commentaire $commentaire) { // } }