15.082
Bearbeitungen
Keine Bearbeitungszusammenfassung |
(Kategorie:Hat leere Faktenbox) |
||
| (10 dazwischenliegende Versionen desselben Benutzers werden nicht angezeigt) | |||
| Zeile 1: | Zeile 1: | ||
p = {} | local p = {} | ||
local com = require("Modul:Common") | local com = require("Modul:Common") | ||
| Zeile 5: | Zeile 5: | ||
local str = require("Modul:String") | local str = require("Modul:String") | ||
local wik = require("Modul:Wiki") | local wik = require("Modul:Wiki") | ||
function p.common_(fbdata) | function p.common_(fbdata) | ||
| Zeile 53: | Zeile 39: | ||
end | end | ||
-- Wartungs-Kategorien | -- Wartungs-Kategorien | ||
if com.isEmpty(fbdata.pargs) then | |||
t = t .. "[[Kategorie:Hat leere Faktenbox]]" | |||
end | |||
if (fbdata.pargs["Bild"] or "") == "" then | if (fbdata.pargs["Bild"] or "") == "" then | ||
if fbdata.kategorie ~= nil then | if fbdata.kategorie ~= nil then | ||
| Zeile 59: | Zeile 48: | ||
t = t .. "[[Kategorie:Ohne Bild]]" | t = t .. "[[Kategorie:Ohne Bild]]" | ||
end | end | ||
elseif not wik. | elseif not wik.pageExists("Bild:" .. fbdata.pargs["Bild"]) then | ||
t = t .. "[[Kategorie:Bild nicht gefunden]]" | t = t .. "[[Kategorie:Bild nicht gefunden]]" | ||
end | end | ||
| Zeile 75: | Zeile 64: | ||
if fbdata.positionscheck and fbdata.kategorie ~= nil and | if fbdata.positionscheck and fbdata.kategorie ~= nil and | ||
not ((fbdata.pargs["lat"] or "") ~= "" or (fbdata.pargs["lon"] or "") ~= "" or | not ((fbdata.pargs["lat"] or "") ~= "" or (fbdata.pargs["lon"] or "") ~= "" or | ||
(fbdata.pargs["location"] or "") ~= "" or wik. | (fbdata.pargs["location"] or "") ~= "" or wik.pageExists("GeoJson:" .. (fbdata.pargs["geojson"] or fbdata.pagename))) then | ||
t = t .. "[[Kategorie:" .. fbdata.kategorie[1] .. ehemals_text .. " ohne Position]]" | t = t .. "[[Kategorie:" .. fbdata.kategorie[1] .. ehemals_text .. " ohne Position]]" | ||
end | end | ||
| Zeile 83: | Zeile 72: | ||
function p.fbdata_(frame) | function p.fbdata_(frame) | ||
-- mw.log("fbdata_(frame)") | |||
-- mw.logObject(frame) | |||
-- Konsolenzeile zum Debuggen: | -- Konsolenzeile zum Debuggen: | ||
-- =p.fbdata_{pargs={a=1}} | -- =p.fbdata_{pargs={a=1}} | ||
| Zeile 90: | Zeile 79: | ||
fbdata.frame, fbdata.pargs = dev.GetFrameAndParentArgs(frame) | fbdata.frame, fbdata.pargs = dev.GetFrameAndParentArgs(frame) | ||
wik.setPagenames(fbdata) | wik.setPagenames(fbdata) | ||
-- mw.logObject(fbdata) | |||
return fbdata | return fbdata | ||
end | end | ||
return p | return p | ||