Content deleted Content added
←Created page with '-- Style for football tables local pp = {} function pp.header(t,Args,p_sub,pos_label,group_col,VTE_text,full_table,results_header_txt) -- Load relevant modules...' |
No edit summary |
||
(12 intermediate revisions by 3 users not shown) | |||
Line 37:
local fa_letter, fa_word_sing, fa_word_plur
local hide_for_against = false
else▼
end▼
-- Use points instead of point for/against
Line 141 ⟶ 116:
tt = p_sub.colhead(tt,20,'<abbr title="Lost">L</abbr>') -- Loss col
end
if do_ratio then▼
if not hide_game_for_against then
tt = p_sub.colhead(tt,20,'<abbr title="'..gfa_word_plur..' for">'..gfa_letter..'F</abbr>') -- For col
Line 172 ⟶ 137:
tt = p_sub.colhead(tt,20,'<abbr title="'..pfa_word_sing..' difference">'..pfa_letter..'D</abbr>') -- Difference col
end
end
end
Line 219 ⟶ 184:
--Some sports use draw as well
local win_perc =
if matches == 0 then
-- Escape for zero matches
win_perc = '—'
▲ else
win_perc = mm._precision_format((2*wins) / (2*matches), 3)
-- Drop the leading zero (from the string)▼
win_perc = string.sub(win_perc,2,string.len(win_perc))▼
▲ -- Drop the leading zero (from the string)
▲ win_perc = string.sub(win_perc,2,string.len(win_perc))
end
Line 366 ⟶ 334:
if not hide_for_against then
table.insert(t,'| style="'..ii_fw..bg_col..'" |'..gfor..'\n') -- GF
table.insert(t,'| style="'..ii_fw..bg_col..'" |'..gaig..'\n') -- GA
Line 399 ⟶ 364:
local status_code, status_called = {}
status_code = { A='Advance to a further round', C='Champion', D='Disqualified',
E='Eliminated', G='Guest', H='Host', N='Did not start', O='Play-off winner',
P='Promoted', Q='Qualified to the phase indicated', R='Relegated', X='?', Y='?', Z='?'}
status_called = { A=false, C=false, D=false, E=false, G=false, H=false,
P=false, Q=false, R=false, T=false, X=false, Y=false, Z=false}
local status_letters = '
-- Status position (before or after read and default)
|