「モジュール:SignalinstWiki」の版間の差分

編集の要約なし
編集の要約なし
74行目: 74行目:
     return finalOutput
     return finalOutput
end
end




85行目: 86行目:
     for category in mw.text.gsplit(categories or "", ",", true) do
     for category in mw.text.gsplit(categories or "", ",", true) do
         if category ~= "" then
         if category ~= "" then
             local categoryName = category:gsub("^カテゴリ:", "")
             local categoryName = mw.text.trim(
                category:gsub("^カテゴリ:", "")
            )


             local pages = frame:expandTemplate{
             local pages = frame:expandTemplate{
91行目: 94行目:
                 args = { category }
                 args = { category }
             }
             }
            pages = mw.text.trim(pages or "")


             output = output
             output = output
                 .. "\n|header" .. i .. "=" .. categoryName
                 .. "\n|header" .. i .. "=" .. categoryName
                 .. "\n|content" .. i .. "=" .. (pages or "")
                 .. "\n|content" .. i .. "=" .. pages


             i = i + 1
             i = i + 1
         end
         end
     end
     end
    -- デバッグ用
    mw.log(output)


     return output
     return output
end
end






return p
return p