<% if @user_orders.any? %>
<% @user_orders.each do |order| %>
<%= order.event.name %>
<%= order.status.humanize %>
<%= order.event.start_time.strftime("%d %B %Y à %H:%M") %>
<%= order.event.venue_name %>
<%= pluralize(order.tickets.count, 'billet') %>
Order #<%= order.id %> • <%= order.created_at.strftime("%m/%d/%Y") %> • €<%= order.total_amount_euros %>
<%= link_to order_path(order),
class: "inline-flex items-center px-3 py-2 bg-purple-600 hover:bg-purple-700 text-white text-xs sm:text-sm font-medium rounded-lg transition-colors duration-200 whitespace-nowrap" do %>
Voir les Détails
<% end %>
<% order.tickets.limit(3).each do |ticket| %>
<%= ticket.ticket_type.name %>
- <%= ticket.first_name %> <%= ticket.last_name %>
<%= link_to ticket_download_path(ticket.qr_code),
class: "text-purple-600 hover:text-purple-800 dark:text-purple-400 dark:hover:text-purple-200" do %>
<% end %>
<% end %>
<% if order.tickets.count > 3 %>
et <%= pluralize(order.tickets.count - 3, 'autre billet') %>
<% end %>
<% end %>
<% if @user_orders.count >= 10 %>
<%= link_to "Voir Toutes Mes Commandes", orders_path, class: "text-purple-600 dark:text-purple-400 hover:text-purple-800 dark:hover:text-purple-200 font-medium transition-colors duration-200 text-sm" %>
<% end %>
<% else %>
Aucune Commande
Vous n'avez pas encore passé de commandes.
<%= link_to events_path, class: "inline-flex items-center px-3 py-2 sm:px-4 sm:py-2 bg-purple-600 text-white rounded-lg hover:bg-purple-700 transition-colors duration-200 text-sm" do %>
Découvrir des Événements
<% end %>
<% end %>