Pumunta sa nilalaman

Module:Sandbox

Mula sa Wikipedia, ang malayang ensiklopedya
Dokumentasyon sa module [gumawa] [purga]
local p = {}

function p.getPropertyValue(frame)
    id = frame.args[1] or ""
    property = frame.args[2] or ""
    
    local entity = mw.wikibase.getEntity( id )
    local value_id = id
    
    if entity then
        if entity.claims then
            if entity.claims[property] then 
                value_id = entity.claims[property]
            end 
        end
    end

    return value_id
end

return p