Template:Calendar entry: Difference between revisions

From stencil.wiki
No edit summary
No edit summary
 
(21 intermediate revisions by the same user not shown)
Line 1: Line 1:
<noinclude>{{Class template|class=Simple event|category=Simple events}}
<noinclude>
== TemplateData ==
== TemplateData ==
<templatedata>
<templatedata>
Line 9: Line 9:
"type": "string",
"type": "string",
"suggestedvalues": [
"suggestedvalues": [
"Art Book Fair",
"Art book fair",
"Comics Expo",
"Comics expo",
"Conference",
"Conference",
"Exhibition",
"Exhibition",
"Meetup",
"Meetup",
"Zine Fest"
"Zine fest"
],
],
"required": true
"required": true
},
},
"status": {
"city": {
"label": "Status",
"label": "City",
"description": "The status of the event.",
"description": "The city of the event (used for sorting, not address display).",
"type": "string"
},
"state_province": {
"label": "State/province",
"description": "The state/province of the event (used for sorting, not address display).",
"type": "wiki-page-name"
},
"country": {
"label": "Country",
"description": "The country of the event (used for sorting, not address display).",
"type": "wiki-page-name",
"required": true
},
"name": {
"label": "Name",
"description": "Unique name of the event.",
"type": "string"
},
"website": {
"label": "Website",
"description": "A link for the event.",
"type": "url"
},
"start_date": {
"label": "Start date",
"description": "Start date of the instance.",
"type": "date",
"required": true
},
"end_date": {
"label": "End date",
"description": "End date of the instance (can be left blank for one-day events).",
"type": "date"
},
"coordinates": {
"label": "Coordinates",
"description": "The latitude and longitude coordinates of the space (optional, to support map display).",
"example": "47.621937, -122.351746",
"type": "string",
"type": "string",
"suggestedvalues": [
"Active",
"Inactive",
"Paused"
],
"suggested": true
"suggested": true
},
},
"instances": {
"application_link": {
"label": "Instances",
"label": "Application link",
"description": "A list of the instances of the event. These are implemented with Template:Event/instance—please use the page form Form:Simple event to edit them.",
"description": "A link to the application form/process for the event.",
"type": "content"
"type": "url"
},
"application_deadline": {
"label": "Application deadline",
"description": "The deadline for application submissions.",
"type": "date"
},
},
"city": {
"venue": {
"label": "City"
"label": "Venue",
"description": "The name of the venue for the instance (can link to a page if there is an associated location, otherwise appears as a red link).",
"type": "wiki-page-name"
},
},
"state_province": {
"access_type": {
"label": "State/province"
"label": "Access type",
"description": "How the event is/was attended (in-person, online, or both).",
"type": "string",
"suggestedvalues": [
"In-person",
"Remote"
],
"suggested": true
},
},
"country": {
"location": {
"label": "Country"
"label": "Location",
"description": "The address of the event (or main address if there are multiple). This can be a full street address or broader region.",
"type": "string"
}
}
},
},
"description": "The main template for the \"Simple event\" class (fairs, conferences, meetups, etc.). This template handles semantic annotation and transcludes display templates for the data (mainly Template:Infobox simple event). This is a simplified test to replace the \"Event\" class which only handles data that is imported from the old wiki.",
"description": "The main template for the \"Calendar entry\" semantic #subobject declaration (holding scheduling data for fairs, conferences, meetups, etc.). This is a simplified test to replace the instance used with the \"Event\" class which only handles data that is imported from the old wiki.",
"format": "block",
"format": "block",
"paramOrder": [
"paramOrder": [
"event_type",
"event_type",
"status",
"name",
"instances",
"start_date",
"end_date",
"website",
"access_type",
"venue",
"location",
"city",
"city",
"state_province",
"state_province",
"country"
"country",
"coordinates",
"application_link",
"application_deadline"
]
]
}
}
Line 58: Line 115:
</noinclude><!--
</noinclude><!--
--><includeonly><!--
--><includeonly><!--
-->{{Infobox simple event
-->{{#subobject:|@category=Calendar entries
| title                = {{PAGENAME}}
| Has parent              = {{PAGENAME}}
| event_type          = {{{event_type|}}}
| Has name                = {{{name|}}}
| status              = {{{status|}}}
| Has event type          = {{{event_type|}}}
| city                = {{{city|}}}
| Has URL                  = {{{website|}}}
| state_province      = {{{state_province|}}}
| Has access type          = {{{access_type|}}}
| country              = {{{country|}}}
| At venue                = {{{venue|}}}
}}<!--
| At location              = {{{location|}}}
-->{{Simple event/upcoming}}<!--
| Has start date          = {{{start_date|}}}
-->[[Category:Simple events]]<!--
| Has end date            = {{{end_date|{{{start_date|}}}}}}
-->{{#if:{{#show:{{PAGENAME}}|?Has event type#}}|
| At coordinates          = {{{coordinates|}}}
  {{#arraymap:{{#show:{{PAGENAME}}|?Has event type#}}|,|@@@@|
    <!-- General Place Type -->
    [[Category:{{#switch:{{lc:@@@@}}
      | art book fair = Art book fairs
      | class = Classes
      | exhibition = Exhibitions
      | zine fest = Zine fests
      | meetup = Meetups
      | comics expo = Comics expos
      | conference = Conferences
    }}]]
  |}}
}}<!--
-->{{#invoke:Geography|geoCategories
  | class = event
  | country = {{#ask:[[-Has subobject::{{PAGENAME}}]][[Category:Instances]]|?In country#|format=plainlist|headers=hide|mainlabel=-}}
  | state_province = {{#ask:[[-Has subobject::{{PAGENAME}}]][[Category:Instances]]|?In state/province#|format=plainlist|headers=hide|mainlabel=-}}
  | city = {{#ask:[[-Has subobject::{{PAGENAME}}]][[Category:Instances]]|?In city#|format=plainlist|headers=hide|mainlabel=-}}
}}<!--
-->{{#set:
  Has event type          = {{{event_type|}}}
| Has status              = {{{status|}}}
| In city                  = {{{city|}}}
| In city                  = {{{city|}}}
| In state/province        = {{{state_province|}}}
| In state/province        = {{{state_province|}}}
| In country              = {{{country|}}}
| In country              = {{{country|}}}
| In region                = {{#if:{{{country|}}}|{{CountryRegionMapping|country={{{country}}}}}|}}
| In region                = {{#if:{{{country|}}}|{{CountryRegionMapping|country={{{country}}}}}|}}
}}{{{instances|}}}<!--
| Has application URL      = {{{application_link|}}}
--></includeonly>
| Has application deadline = {{{application_deadline|}}}
}}<nowiki/></includeonly>

Latest revision as of 13:36, 3 September 2025

TemplateData

The main template for the "Calendar entry" semantic #subobject declaration (holding scheduling data for fairs, conferences, meetups, etc.). This is a simplified test to replace the instance used with the "Event" class which only handles data that is imported from the old wiki.

Template parameters[Edit template data]

This template prefers block formatting of parameters.

ParameterDescriptionTypeStatus
Event typeevent_type

Type of event.

Suggested values
Art book fair Comics expo Conference Exhibition Meetup Zine fest
Stringrequired
Namename

Unique name of the event.

Stringoptional
Start datestart_date

Start date of the instance.

Daterequired
End dateend_date

End date of the instance (can be left blank for one-day events).

Dateoptional
Websitewebsite

A link for the event.

URLoptional
Access typeaccess_type

How the event is/was attended (in-person, online, or both).

Suggested values
In-person Remote
Stringsuggested
Venuevenue

The name of the venue for the instance (can link to a page if there is an associated location, otherwise appears as a red link).

Page nameoptional
Locationlocation

The address of the event (or main address if there are multiple). This can be a full street address or broader region.

Stringoptional
Citycity

The city of the event (used for sorting, not address display).

Stringoptional
State/provincestate_province

The state/province of the event (used for sorting, not address display).

Page nameoptional
Countrycountry

The country of the event (used for sorting, not address display).

Page namerequired
Coordinatescoordinates

The latitude and longitude coordinates of the space (optional, to support map display).

Example
47.621937, -122.351746
Stringsuggested
Application linkapplication_link

A link to the application form/process for the event.

URLoptional
Application deadlineapplication_deadline

The deadline for application submissions.

Dateoptional