Aggiunge i tornei con hub, pagina pubblica e tabellone per semifinali e finali.
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -0,0 +1,34 @@
|
||||
<div class="card">
|
||||
<p style="color:#888"><%= t("tournaments.form.formats.#{@tournament.format_kind}") %></p>
|
||||
|
||||
<% if @tournament.uses_groups? %>
|
||||
<h2><%= t("tournaments.hub.tabs.struttura") %></h2>
|
||||
<ul>
|
||||
<% @groups.each do |group| %>
|
||||
<li style="margin-bottom:8px">
|
||||
<%= group.name %>
|
||||
<% if @writable %>
|
||||
<%= button_to t("matches.index.delete"), public_tournament_group_path(@tournament, group),
|
||||
method: :delete, class: "btn btn-secondary", style: "padding:4px 10px;font-size:0.8rem;display:inline",
|
||||
form: { data: { turbo_confirm: group.name }, style: "display:inline" } %>
|
||||
<% end %>
|
||||
</li>
|
||||
<% end %>
|
||||
</ul>
|
||||
<% if @writable %>
|
||||
<%= form_with url: public_tournament_groups_path(@tournament), method: :post do %>
|
||||
<%= text_field_tag "tournament_group[name]", nil, placeholder: t("tournaments.hub.add_group") %>
|
||||
<%= submit_tag t("tournaments.hub.add_group"), class: "btn btn-secondary" %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
|
||||
<% if @tournament.uses_knockout? %>
|
||||
<h2 style="margin-top:20px"><%= t("tournaments.hub.tabs.tabellone") %></h2>
|
||||
<ul>
|
||||
<% @rounds.each do |round| %>
|
||||
<li><%= round.name %></li>
|
||||
<% end %>
|
||||
</ul>
|
||||
<% end %>
|
||||
</div>
|
||||
Reference in New Issue
Block a user