Modulo:Fumetto e animazione/sandbox: differenze tra le versioni
Contenuto cancellato Contenuto aggiunto
m versione attuale |
semplifico |
||
Riga 67:
return adj
end
-- ========================================================================
-- Individua e restituisce l'anno in una stringa, se presente
-- ========================================================================
local function get_year(str)
end
Riga 78 ⟶ 87:
local function categorizza(args, base_name, table_name, lowercase)
local categories = {}
local adj▼
local
▲ local adj
if name_value then▼
▲ if not name_value then break end
name_value = mDelink._main({ name_value })
if lowercase then name_value = mw.ustring.lower(name_value) end
if table_name == 'paese_TV' then
adj = get_adj(name_value, 'fp')
elseif table_name == 'paese_film_DTV' then
adj = get_adj(name_value, 'mp')
if adj then
categories[#categories+1] = 'Film d\'animazione ' .. adj
▲ anno = tonumber(args['data inizio']:match('%d%d%d%d'))
▲ if anno then
▲ categories[#categories+1] = 'Film ' .. adj .. ' del ' .. anno
end
elseif table_name == 'paese_webserie' then
Riga 125 ⟶ 130:
elseif table_name == 'etichetta_sottotipo' or table_name == 'editore_sottotipo' then
categories[#categories+1] = get_category(args.sottotipo .. ' ' .. name_value, table_name)
local category = get_category(name_value, table_name)
▲ while true do
▲ name_value = args[base_name .. ' ' .. tostring(index)]
end
return categories
Riga 293 ⟶ 247:
-- Categorizzazione per anno delle opere previste
elseif args.tipo and tipo ~= nil and args['data inizio'] then
▲ anno = tonumber(args['data inizio']:match('%d%d%d%d'))
▲ end
▲ anno = tonumber(args['data fine']:match('%d%d%d%d'))
-- Categoria di errore quando data inizio/data fine sono compilati
-- ma non si rilevano le quattro cifre dell'anno in entrambi
|