יחידה:PropertyLink: הבדלים בין גרסאות בדף

מאין תקציר עריכה
מ שחזור לגרסה 16642540 מתאריך 16:53, 13 במרץ 2015 מאת ערן
שורה 12: שורה 12:
end
end
return ''
return ''
end
function getPropertyQualifier(property, qualifier)
local wikidataModule = require('Module:Wikidata')
local entity = mw.wikibase.getEntityObject()
    if not entity or not entity.claims then return end --the entity doesnt exist or have no claims
    local propertyVals = entity.claims[property]
    if not propertyVals then return end --no such property for this item
value, error = wikidataModule.getValueOfClaim(propertyVals[0], qualifier, nil)
return value
end
end


שורה 134: שורה 123:
     ['מאפיין'] = property,
     ['מאפיין'] = property,
     getProperty = getProperty,
     getProperty = getProperty,
    getPropertyQualifier = getPropertyQualifier,
     getImageLink = getImageLink,
     getImageLink = getImageLink,
     getLabel = getLabel,
     getLabel = getLabel,