Module:Infobox/TeamHist

local m_role = require('Module:Role') local m_team = require('Module:Team') local util_args = require('Module:ArgsUtil')

local p = {}

function p.teamHist(storeto, args) local i = 1 if args['teamhist' .. 1] then local tbl = mw.html.create('table'):addClass('teamhist') while args['teamhist' .. i] do			tbl:tag('tr') :tag('td') :addClass('teamdate') :wikitext(args['teamdate' .. i] or '') :done :tag('td') :wikitext(m_role.onlyimage(args['teamrole' .. i], { sub = util_args.castAsBool(args['issub' .. i]) })) :wikitext('&#8198;') :wikitext(m_team.rightmediumlinked(args['teamhist' .. i])) i = i + 1 end storeto.teamhist = tostring(tbl) i = i - 1 end return { team = args['teamhist' .. i] and m_team.teamlinkname(args['teamhist' .. i]), date = args['teamdate' .. i], role = args['teamrole' .. i]	} end

return p