Anonimo

Modulo:DTSpecific: differenze tra le versioni

Da Wikitrek.
m
nessun oggetto della modifica
(BoxSecSeries can be used for Episodes too)
mNessun oggetto della modifica
 
(3 versioni intermedie di uno stesso utente non sono mostrate)
Riga 80: Riga 80:
         local Row = ""
         local Row = ""
         local CurrChar
         local CurrChar
         for k, v in pairs(QueryResult.results) do
         for k, v in ipairs(QueryResult.results) do
         -- v.fulltext represents EPISODE
         -- v.fulltext represents EPISODE
         -- v.printouts[Actor][1].fulltext represents CHARACTER
         -- v.printouts[Actor][1].fulltext represents CHARACTER
Riga 165: Riga 165:
local FinalString = ""
local FinalString = ""
local Actor = mw.title.getCurrentTitle().text
local Actor = mw.title.getCurrentTitle().text
local QueryResult = mw.smw.getQueryResult('[[Interprete::' .. Actor .. ']]|?' .. Actor .. '|sort=Numero di produzione|order=asc')
local QueryResult = mw.smw.getQueryResult('[[Interprete::' .. Actor .. ']]|?' .. Actor .. '|limit=500|sort=Numero di produzione|order=asc')
if QueryResult == nil then
if QueryResult == nil then
Riga 196: Riga 196:
for ID, Group in pairs(FinalArray) do
for ID, Group in pairs(FinalArray) do
-- Prepares string
FinalString = FinalString .. "* '''[[" .. ID .. "]]''': [[" .. table.concat(Group, "]], [[") .. "]]" .. string.char(10)
FinalString = FinalString .. "* '''[[" .. ID .. "]]''': [[" .. table.concat(Group, "]], [[") .. "]]" .. string.char(10)
-- Add "Personaggio" as semantic property
mw.smw.set("Personaggio = " .. ID)
end
end
Riga 403: Riga 406:
    --"fulltext": "Star Trek: Strange New Worlds",
    --"fulltext": "Star Trek: Strange New Worlds",
    LI =  mw.html.create('li')
    LI =  mw.html.create('li')
        LI:wikitext("[[" .. CurrSeries.fulltext .. "|" .. CurrSeries.printouts.Abbreviazione[1] .. "]]")
        LI:wikitext("[[" .. (CurrSeries.fulltext or "NullFulltext") .. "|" .. (CurrSeries.printouts.Abbreviazione[1] or "NullAbbreviazione") .. "]]")
       
       
        UL:node(LI)
        UL:node(LI)