Difference between revisions of "Template:Event"

From Pirate Party Belgium
Jump to: navigation, search
m
 
(48 intermediate revisions by the same user not shown)
Line 1: Line 1:
<includeonly>{{#if: {{{page|}}} | [[{{{page}}}{{!}} }}{{#if: {{{date|}}}  
+
<includeonly>{{#vardefine: date
| {{#time:D j F Y
+
| {{#if: {{{date|}}}  
  |{{{date}}}
+
  | {{#time:D j F Y|{{{date}}}|{{int:language-code}} }}
  |{{{lang|en}}}
+
  | ?
 +
  }}{{#if: {{{time|}}}  
 +
  | , {{#time:{{int:sidebar-time-format}}|{{{time}}} }}
 
   }}
 
   }}
| ?
+
}}{{#if: {{{page|}}}
}}{{#if: {{{time|}}}  
+
| {{#if: {{{title|}}}
| , {{#time:
+
  | '''[[{{{page}}}|{{{title}}}]]'''<br />{{#var: date}}
     {{#switch: {{{lang|}}}  
+
  | [[{{{page}}}|{{#var:date}}]]
    | fr = H\hi
+
  }}
     | nl = H\ui
+
| {{#var: date}}
     | g:ia
+
}}<br />{{#if: {{{location|}}}
 +
| {{{location}}}
 +
| {{#if: {{{venue|}}}
 +
  | {{#if: {{{linkvenue|}}}
 +
    | [{{{linkvenue|}}} {{{venue|}}}]
 +
     | {{{venue}}}
 +
    }} {{#if: {{{address|}}} | – {{{address}}} }}
 +
  | {{#if: {{{address|}}} | {{{address}}} | ? }}
 +
  }}{{#switch: {{lc:{{{venue|}}}}} | internet = | online =
 +
  | #default = <br />{{#if: {{{postalcode|}}}
 +
     | {{{postalcode}}} {{#if: {{{city|}}} | {{{city}}} | ? }}
 +
     | {{#if: {{{city|}}} | {{{city}}} | ? }}
 
     }}
 
     }}
  |{{{time}}}
 
 
   }}
 
   }}
}}{{#if: {{{page|}}} | ]] }}<br />{{#if: {{{venue|}}}
+
}}{{#ifeq: {{{nomap|}}} | true
| {{#if: {{{linkvenue|}}}
+
|
   | [{{{linkvenue}}} {{{venue}}}]
+
| {{#vardefine: coords
  | {{{venue}}}
+
   | {{Coordinates
  }} {{#if: {{{address|}}} | {{{address}}} }}
+
    |address={{{address|}}}
| {{#if: {{{address|}}} | {{{address}}} | ? }}
+
    |venue={{{venue|}}}
}}<br />{{#if: {{{postalcode|}}}
+
    |city={{{city|}}}
| {{{postalcode}}} {{#if: {{{city|}}} | {{{city}}} | ? }}
+
    }}
| {{#if: {{{city|}}} | {{{city}}} | ? }}  
+
  }}{{#display_map: {{#var: coords}} | height=225px | width=300px | enablefullscreen = yes | scrollwheelzoom = no }}
 
}} {{#if: {{{nocat|}}}  
 
}} {{#if: {{{nocat|}}}  
 
|  
 
|  
Line 28: Line 40:
 
}} {{#if: {{{noproperties|}}}  
 
}} {{#if: {{{noproperties|}}}  
 
|  
 
|  
| {{#set:  
+
| {{#switch: {{SUBPAGENAME}}
  In language={{{lang|en}}}
+
| fr = | nl = | en = | de =
  |Has date={{#time:Y/m/d H:i| {{{date}}} {{{time|}}} }}
+
| {{#arraymap:{{#if: {{{date|}}} | {{{date}}} | ? }}|,|{date}|{{#subobject:
  |Has time={{{time|}}}
+
      {{#ifeq: {date} | ?
  |Has address={{{address|}}}
+
      |
  |In venue={{{venue|}}}
+
      | {{#time: d m Y|{date} }}
  |Has link venue={{{linkvenue|}}}
+
      }}
  |In city={{{city|}}}
+
      |Has title={{{title|}}}
  |In postal code={{{postalcode|}}}
+
      |Has date={{#ifeq: {date} | ?
  |Organized by={{{workgroup|}}}
+
        |
  |Has coordinates={{Coordinates
+
        | {{#time:Y/m/d H:i|{date} {{{time|}}} }}
    |address={{{address|}}}
+
        }}
    |venue={{{venue|}}}
+
      |Has end date={{#ifeq: {date} | ?
    |city={{{city|}}}
+
        |
 +
        | {{#time:Y/m/d H:i|{date} {{{time|}}} }}  
 +
        }}
 +
      |Has time={{{time|}}}
 +
      |Has end time={{{time|}}}
 +
      |Has address={{{address|}}}
 +
      |In venue={{{venue|}}}
 +
      |Has link venue={{{linkvenue|}}}
 +
      |In city={{{city|}}}
 +
      |In postal code={{{postalcode|}}}
 +
      |Has coordinates={{#if: {{#varexists:coords}}
 +
        | {{#var:coords}}  
 +
        | {{Coordinates
 +
          |address={{{address|}}}
 +
          |venue={{{venue|}}}
 +
          |city={{{city|}}}
 +
          }}
 +
        }}
 +
      |Has location={{#if: {{{venue|}}}
 +
        | {{{venue}}} {{#if: {{{address|}}}{{{city|}}} | – }}
 +
        }} {{#if: {{{address|}}}
 +
        | {{{address}}}{{#if: {{{city|}}} | , }}
 +
        }} {{{city|}}}
 +
      |Has url={{fullurl:{{FULLPAGENAME}}}}
 +
      |Has event type={{{type|}}}
 +
      |Organized by={{{workgroup|}}}|+sep=,
 +
      |Has page={{FULLPAGENAME}}
 +
      }}|
 
     }}
 
     }}
 
   }}
 
   }}
 
}}</includeonly>
 
}}</includeonly>

Latest revision as of 19:11, 23 March 2020