62 737
modifications
Nous sommes une association à but non lucratif et nos sites sont sans publicité, vous pouvez nous aider en
Aucun résumé des modifications |
Aucun résumé des modifications |
||
Ligne 42 : | Ligne 42 : | ||
function p.buildlist(part) | function p.buildlist(part) | ||
local title = part.title | local title = part.title | ||
local | local prefix = part.prefix | ||
if not title then | local maxitems = part.max | ||
if not title or not prefix or not maxitems then | |||
return nil | return nil | ||
end | end | ||
-- create items | -- create items | ||
local | local items = {} | ||
for i = 1, maxitems do | |||
local v = p.builditem({ value = prefix..i }) | |||
if not v then | |||
break | |||
end | end | ||
table.insert(items, v) | |||
end | end | ||
if | if #items == 0 then | ||
return nil | return nil | ||
end | end | ||
-- create list | -- create list | ||
Ligne 175 : | Ligne 164 : | ||
['row'] = p.buildrow, | ['row'] = p.buildrow, | ||
['list'] = p.buildlist, | ['list'] = p.buildlist, | ||
} | } | ||
modifications