« Module:Infobox/Monument » : différence entre les versions
mAucun résumé des modifications |
ajoute de 4 paramètre de Modèle:Infobox Édifice religieux |
||
| Ligne 2 : | Ligne 2 : | ||
local general = require "Module:Infobox/Fonctions" | local general = require "Module:Infobox/Fonctions" | ||
local wikidata = require "Module:Wikidata" | local wikidata = require "Module:Wikidata" | ||
local function getDate(event) | |||
return wikidata.getTheDate{property = 'P793', targetvalue = 'Q331483', addcat = true, entity = item} | |||
end | |||
return | return | ||
| Ligne 12 : | Ligne 16 : | ||
building.mainimage(), | building.mainimage(), | ||
{type = 'table', title = 'Présentation', rows = { | {type = 'table', title = 'Présentation', rows = { | ||
{type = ' | {type = 'row', label = 'Noms précédents', value = 'noms précédents'}, | ||
{type = ' | {type = 'row', label = 'Surnom(s)', value = 'surnom'}, | ||
{type = ' | {type = 'row', label = 'Nom complet', value = 'nom complet'}, | ||
{type = ' | {type = 'row', label = 'Type', value = 'type'}, --property = 'P31'}, | ||
{type = 'row', label = 'Culte', value = 'culte'}, | |||
{type = 'row', label = 'Rattachement', value = 'rattachement'}, | |||
building.archistyle(), | building.archistyle(), | ||
building.creator(), | building.creator(), | ||
building.material(), | building.material(), | ||
building.construction(), | building.construction(), | ||
{type = ' | {type = 'row', label = 'Autre campagnes de travaux', value = 'autres travaux'}, | ||
wikidata = function(item) return | {type = 'row', label = 'Date de désacralisation', value = 'date de désacralisation', | ||
wikidata = function(item) return getDate('Q19688839') end | |||
}, | }, | ||
{type = ' | {type = 'row', label = 'Date de démolition', value = 'date de démolition', | ||
{type = ' | wikidata = function(item) return getDate('Q331483') end | ||
{type = ' | }, | ||
{type = ' | {type = 'row', label = 'Commanditaire', value = 'commanditaire', property = 'P88'}, | ||
{type = 'row', label = 'Hauteur', value = 'hauteur'}, | |||
{type = 'row', label = 'Destination initiale', value = 'destination initiale'}, | |||
{type = 'row', label = 'Destination actuelle', value = 'destination actuelle'}, | |||
building.owner(), | building.owner(), | ||
building.operator(), | building.operator(), | ||
| Ligne 40 : | Ligne 50 : | ||
}, | }, | ||
{type = 'table', title = 'Accès et transport', rows = { | {type = 'table', title = 'Accès et transport', rows = { | ||
{type = ' | {type = 'row', label = 'Stationnement', value = 'stationnement'}, | ||
{type = ' | {type = 'row', label = 'Gare', value = 'gare'}, | ||
{type = ' | {type = 'row', label = 'Métro', value = 'métro'}, | ||
{type = ' | {type = 'row', label = 'Tramway', value = 'tramway'}, | ||
{type = ' | {type = 'row', label = 'Autobus', value = 'bus'}, | ||
}, | }, | ||
}, | }, | ||
Version du 27 mars 2015 à 14:59
local building = require "Module:Infobox/Fonctions/Bâtiment" local general = require "Module:Infobox/Fonctions" local wikidata = require "Module:Wikidata"
local function getDate(event) return wikidata.getTheDate{property = 'P793', targetvalue = 'Q331483', addcat = true, entity = item} end
return { maincolor = '#E6E3CF', parts =
{
general.title(), general.logo(), building.mainimage(), {type = 'table', title = 'Présentation', rows = { {type = 'row', label = 'Noms précédents', value = 'noms précédents'}, {type = 'row', label = 'Surnom(s)', value = 'surnom'}, {type = 'row', label = 'Nom complet', value = 'nom complet'}, {type = 'row', label = 'Type', value = 'type'}, --property = 'P31'}, {type = 'row', label = 'Culte', value = 'culte'}, {type = 'row', label = 'Rattachement', value = 'rattachement'}, building.archistyle(), building.creator(), building.material(), building.construction(), {type = 'row', label = 'Autre campagnes de travaux', value = 'autres travaux'}, {type = 'row', label = 'Date de désacralisation', value = 'date de désacralisation', wikidata = function(item) return getDate('Q19688839') end }, {type = 'row', label = 'Date de démolition', value = 'date de démolition', wikidata = function(item) return getDate('Q331483') end }, {type = 'row', label = 'Commanditaire', value = 'commanditaire', property = 'P88'}, {type = 'row', label = 'Hauteur', value = 'hauteur'}, {type = 'row', label = 'Destination initiale', value = 'destination initiale'}, {type = 'row', label = 'Destination actuelle', value = 'destination actuelle'}, building.owner(), building.operator(), building.protection(), building.website(), } }, {type = 'table', title = 'Géographie', rows = { building.country(), building.historicalregion(), building.adminlocation(), } }, {type = 'table', title = 'Accès et transport', rows = { {type = 'row', label = 'Stationnement', value = 'stationnement'}, {type = 'row', label = 'Gare', value = 'gare'}, {type = 'row', label = 'Métro', value = 'métro'}, {type = 'row', label = 'Tramway', value = 'tramway'}, {type = 'row', label = 'Autobus', value = 'bus'}, }, }, {type = 'table', title = 'Localisation', rows = { building.coordinates(), } }, building.geoloc(), } }