Difference between revisions of "Template:EventsForThisPage"
(restored by csi_restorechanges) |
|||
Line 2: | Line 2: | ||
{{{pg={{{page|}}}}}} | {{{pg={{{page|}}}}}} | ||
{{#arr:dataloop | {{#arr:dataloop | ||
− | |{{#data:select | + | |{{#data:select |
− | + | | Event.# | |
− | + | | #where = ({{{fld}}}={{#cast:ref|{{{1|{{{page|{{PAGENAME}}}}}}}}|db}} or {{{fld}}} in (select page_title from redirect join page on rd_from=page_id where rd_title={{#cast:ref|{{{1|{{{page|{{PAGENAME}}}}}}}}|db}})) and Event.Country!='Slovenia' | |
− | + | | #limit = 1}} | |
− | }} | + | | first = <div class="contact-info-title">{{#if:{{{1|}}}|<h2>{{{1}}}</h2>| |
− | | first = <div class="contact-info-title">{{#if:{{{1|}}}|<h2>{{{1}}}</h2>| | + | {{#ifeq:{{{field}}}|country |
− | {{#ifeq:{{{field}}}|country | + | |{{#title:link|:Culture.si:Events/all/all/{{{pg}}}||Events in {{{pg|}}}}} |
− | |{{#title:link|:Culture.si:Events/all/all/{{{pg}}}||Events in {{{pg|}}}}} | + | |[[:Culture.si:Events|Events {{#if:{{{pg|}}}| {{{pg|}}}|abroad}}]] |
− | |[[:Culture.si:Events|Events {{#if:{{{pg|}}}| {{{pg|}}}|abroad}}]] | + | }}}} |
− | }}}} | + | </div>}} |
− | </div> | + | |
− | }} | ||
<div> | <div> | ||
{{#arr:dataloop | {{#arr:dataloop | ||
Line 36: | Line 35: | ||
| first = <ul class="events"> | | first = <ul class="events"> | ||
| each = {{#eval:wrap|{{{template|ListEvent}}}}} | | each = {{#eval:wrap|{{{template|ListEvent}}}}} | ||
− | | last = </ul> | + | | last = </ul><a href="#" class="show-more-events">Show more</a> |
}} | }} | ||
{{#arr:dataloop | {{#arr:dataloop | ||
− | |{{#data:select | + | |{{#data:select |
− | + | | Description=Event.Description | |
− | + | | Start = Event.Start | |
− | + | | End = Event.End | |
− | + | | Url = Event.Url | |
− | + | | Editcall = Event.Editcall | |
− | + | | Organizer_url = Event.Organizer_url | |
− | + | | More_url = Event.More_url | |
− | + | | Work_url = Event.Work_url | |
− | + | | Festival = Event.Festival | |
− | + | | City = {{groupLinks|Event.City}} | |
− | + | | Venue = {{groupLinks|Event.Venue}} | |
− | + | | Country = {{groupLinks|Event.Country}} | |
− | + | | #groupby = 1,2,3,4,5,6,7,8,9 | |
− | + | | #where = ({{{fld}}}={{#cast:ref|{{{1|{{{page|{{PAGENAME}}}}}}}}|db}} or {{{fld}}} in (select page_title from redirect join page on rd_from=page_id where rd_title={{#cast:ref|{{{1|{{{page|{{PAGENAME}}}}}}}}|db}})) and (Event.Country!='Slovenia') and to_char(coalesce(Event.End,Event.Start),'YYYYMMDD') < '{{#timel:Ymd|{{CURRENTDATE}}}}' | |
− | + | | #limit = 150 | |
− | + | | #orderby = Event.Start DESC}} | |
− | }} | + | | first = <div class="events-title">Past Events</div><ul class="events"> |
− | | first = <div class="events-title">Past Events</div><ul class="events"> | + | | each = {{#eval:wrap|{{{template|ListEvent}}}}} |
− | | each = {{#eval:wrap|{{{template|ListEvent}}}}} | + | | last = </ul>{{#eval:html|<a href="#" class="show-more-events">Show more</a>}}}} |
− | | last = </ul> | ||
− | }} | ||
</div> | </div> |
Revision as of 01:13, 11 February 2021