5466
редагувань
Admin (обговорення | внесок) Немає опису редагування |
Admin (обговорення | внесок) Немає опису редагування |
||
| Рядок 148: | Рядок 148: | ||
if player_in_game and #cells >= 15 then | if player_in_game and #cells >= 15 then | ||
local tournament = cells[3] or "" | local tournament = cells[3] or "" | ||
local short_name = cells[4] or "" | local short_name = cells[4] or "" | ||
| Рядок 159: | Рядок 157: | ||
table.insert(games, { | table.insert(games, { | ||
tournament = tournament, | tournament = tournament, | ||
short = short_name, | short = short_name, | ||
| Рядок 194: | Рядок 190: | ||
local table_html = { | local table_html = { | ||
'{| class="wikitable sortable" style="width: 100%; font-size: 14.5px;"', | '{| class="wikitable sortable" style="width: 100%; font-size: 14.5px;"', | ||
' | '! Турнір !! Роль !! Результат !! Запис', | ||
'|-' | '|-' | ||
} | } | ||
| Рядок 201: | Рядок 197: | ||
local result_text = game.result | local result_text = game.result | ||
if game.result == "Перемога" then | if game.result == "Перемога" then | ||
result_text = "<span style='color: | result_text = "<span style='color:#4caf50; font-weight:normal;'>Перемога</span>" | ||
elseif game.result == "Поразка" then | elseif game.result == "Поразка" then | ||
result_text = "<span style='color:indianred;'>Поразка</span>" | result_text = "<span style='color:indianred; font-weight:normal;'>Поразка</span>" | ||
end | end | ||
local link_display = "" | local link_display = "" | ||
if game.link and game.link ~= "" then | if game.link and game.link ~= "" then | ||
link_display = string.format(' | link_display = string.format( | ||
'<a href="%s" class="external" style="display:inline-block; padding:4px 12px; background-color:white; color:black; text-decoration:none; border-radius:4px; font-size:13px;">Запис</a>', | |||
game.link | |||
) | |||
end | end | ||
| Рядок 214: | Рядок 213: | ||
table.insert(table_html, string.format( | table.insert(table_html, string.format( | ||
' | '| style="text-align:center; padding: 8px;" | %s || style="text-align:center; padding: 8px;" | %s || style="text-align:center; padding: 8px;" | %s || style="text-align:center; padding: 8px;" | %s', | ||
tournament_link, | tournament_link, | ||
game.role, | game.role, | ||