יחידה:תבנית מידע/אישיות: הבדלים בין גרסאות בדף

מאין תקציר עריכה
מאין תקציר עריכה
שורה 22: שורה 22:
local function getDeathLabel(deathCause, entityId)
local function getDeathLabel(deathCause, entityId)
local result=''
local result=''
local fromWikidata=nil
entityId = entityId or mw.wikibase.getEntityIdForCurrentPage()
entityId = entityId or mw.wikibase.getEntityIdForCurrentPage()
if ( deathCause == nil or deathCause =='' ) and entityId ~= nil then
if ( deathCause == nil or deathCause =='' ) and entityId ~= nil then
שורה 28: שורה 29:
if deathCauseWikidata then
if deathCauseWikidata then
deathCause = mw.wikibase.renderSnak(deathCauseWikidata)
deathCause = mw.wikibase.renderSnak(deathCauseWikidata)
fromWikidata=true
end
end
end
end
שורה 41: שורה 43:
elseif deathCause == 'הוצא להורג' or deathCause == 'הוצאה להורג' or deathCause == 'עונש מוות' or deathCause == 'תלייה' then
elseif deathCause == 'הוצא להורג' or deathCause == 'הוצאה להורג' or deathCause == 'עונש מוות' or deathCause == 'תלייה' then
return 'הוצאה להורג'
return 'הוצאה להורג'
else result='[[קטגוריה:ערכים עם סיבת מוות שגויה]]'
elseif not fromWikidata then result='[[קטגוריה:ערכים עם סיבת מוות שגויה]]'
end
end
end
end