Worlds Bets
Some checks failed
CI / scan_ruby (push) Has been cancelled
CI / scan_js (push) Has been cancelled
CI / lint (push) Has been cancelled
CI / test (push) Has been cancelled

This commit is contained in:
sto
2026-09-06 10:07:47 +02:00
parent 49e49dc93d
commit dae86bd1ea
33 changed files with 1337 additions and 1 deletions

View File

@@ -0,0 +1,49 @@
= render "worlds_nav"
h4.mt-3 = t("worlds.view.subtitle", name: @world_bet.name).html_safe
.row.mt-3
.col
h5 = t("worlds.view.world_participants")
table.table.table-striped.table-hover
thead
tr
th = t("worlds.view.participant")
th = t("worlds.view.multiplier")
th Q
th S
th F
th = t("worlds.view.total")
tbody
- @world_participants.each_with_index do |p, i|
tr
td = Flags.get_flag(p.world_country.code) + " " + p.name
td style="color: cadetblue;"
= "x#{WorldBet.multiplier(i)}"
td = "<span style='color: orange'>#{p.qualifier_result || "?"}</span> > <span style='color: green'>#{WorldBet.points(p.qualifier_result)}p</span>".html_safe
td = "<span style='color: orange'>#{p.semifinal_result || "?"}</span> > <span style='color: green'>#{WorldBet.points(p.semifinal_result) * 2}p</span>".html_safe
td = "<span style='color: orange'>#{p.final_result || "?"}</span> > <span style='color: green'>#{WorldBet.points(p.final_result) * 4}p</span>".html_safe
td = "<span style='color: green'>#{p.score || 0}</span> x <span style='color: cadetblue'>#{WorldBet.multiplier(i)}</span> = <span style='color: green'>#{(p.score || 0) * WorldBet.multiplier(i)}p</span>".html_safe
.row.mt-3
.col
h5 = t("worlds.view.french_participants")
table.table.table-striped.table-hover
thead
tr
th = t("worlds.view.participant")
th = t("worlds.view.multiplier")
th Q
th S
th F
th = t("worlds.view.total")
tbody
- @french_participants.each_with_index do |p, i|
tr
td = Flags.get_flag(p.world_country.code) + " " + p.name
td style="color: cadetblue;"
= "x#{WorldBet.multiplier(i)}"
td = "<span style='color: orange'>#{p.qualifier_result || "?"}</span> > <span style='color: green'>#{WorldBet.points(p.qualifier_result)}p</span>".html_safe
td = "<span style='color: orange'>#{p.semifinal_result || "?"}</span> > <span style='color: green'>#{WorldBet.points(p.semifinal_result) * 2}p</span>".html_safe
td = "<span style='color: orange'>#{p.final_result || "?"}</span> > <span style='color: green'>#{WorldBet.points(p.final_result) * 4}p</span>".html_safe
td = "<span style='color: green'>#{p.score || 0}</span> x <span style='color: cadetblue'>#{WorldBet.multiplier(i)}</span> = <span style='color: green'>#{(p.score || 0) * WorldBet.multiplier(i)}p</span>".html_safe