From 44b74ef5129f858bcde5fe1202c6ba9a6868a767 Mon Sep 17 00:00:00 2001 From: kd Date: Tue, 27 Jan 2026 14:27:56 +0400 Subject: [PATCH] f --- app/views/livres/index.html.erb | 37 ++++++++++++++++++++------------- 1 file changed, 22 insertions(+), 15 deletions(-) diff --git a/app/views/livres/index.html.erb b/app/views/livres/index.html.erb index 4baf364..c5aec0e 100644 --- a/app/views/livres/index.html.erb +++ b/app/views/livres/index.html.erb @@ -1,5 +1,4 @@

Catalogue de la bibliothèque

- <%= form_with url: livres_path, method: :get, local: true do %>

Rechercher un livre : @@ -7,19 +6,27 @@ <%= submit_tag "Rechercher" %>

<% end %> -

Nombre total de livres : <%= @livres.count %>

- - - + + + + + + + + + + + <% @livres.each do |livre| %> + + + + + + + <% end %> + +
TitreAuteurDate de sortieActions
<%= livre.titre %><%= livre.auteur %><%= livre.date_de_sortie %> + <%= button_to "Supprimer", livre_path(livre), method: :delete, data: { confirm: "Supprimer ce livre ?" } %> +

<%= link_to "Ajouter un nouveau livre", new_livre_path %>