Difference between revisions of "Module:Infobox"

Jump to navigation Jump to search
96 bytes removed ,  19:58, 11 August 2022
no edit summary
Line 71: Line 71:


local function infoboxData(data, label, default)
local function infoboxData(data, label, default)
mw.log(data)
local result
local result
if data or default then
if data or default then
Line 100: Line 99:
if buildingData or args['image'] then
if buildingData or args['image'] then
result = mainBox(building)
result = mainBox(building)
mw.log(tostring(result))
if args['image'] then
if args['image'] then
result:node(infoboxImage(args['image'], args['caption']))
result:node(infoboxImage(args['image'], args['caption']))
end
end
mw.log(tostring(result))
 
--Production group
--Production group
local workers = buildingData.workers
local workers = buildingData.workers
Line 127: Line 125:
for k, v in ipairs(production) do
for k, v in ipairs(production) do
result:node(v)
result:node(v)
mw.log(tostring(result))
end
end
end
end

Navigation menu