-
Notifications
You must be signed in to change notification settings - Fork 5
/
Scotland.html
51 lines (51 loc) · 1.99 KB
/
Scotland.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
---
title: Scotland LUGs
layout: default
permalink: lugs/Scotland/
is_regional: yes
---
{% assign sortedPosts = site.categories.Scotland | sort: 'title' %}
{% assign postStatus = "Active" | split: "," %}
{% for post in sortedPosts %}
{% unless postStatus contains post.status %}
{% assign postStatus = postStatus | push: post.status %}
{% endunless %}
{% endfor %}
{% assign statusCount = postStatus.size %}
<table width=100%>
<thead>
<tr>
<th>Title</th>
<th>Established</th>
<th>
{% if statusCount == 1 %}
Status: {% for status in postStatus %}{{ status }}{% endfor %}
{% else %}
<label for="statusFilter">Status:</label>
<select id="statusFilter">
{% for status in postStatus %}
<option value="{{ status }}"{% if status == "Active" %} selected="selected"{% endif %}>{{ status }}</option>
{% endfor %}
<option value="all">All</option>
</select>
{% endif %}
</th>
<th>Last updated</th>
<th>Region</th>
</tr>
</thead>
<tbody>
{% for post in sortedPosts %}
<tr style="{{ style }}{% cycle ' background-color: #f2f2f2','' %}" class="{{ this_post_status }}">
<th><a href="{{ post.url }}">{{ post.title | escape }}</a></th>
<!-- <td>{% if post.website and post.website != '' %}<a href="{{ post.website }}">{{ post.website }}</a>{% endif %}</td> -->
<td>{% if post.established_date and post.established_date != '' %}{{ post.established_date | date: "%Y/%m" }}{% endif %}</td>
<td>{{ post.status | default: 'Active' }}</td>
<td>{% if post.last_update and post.last_update != '' %}{{ post.last_update | date: "%Y/%m" }}{% endif %}</td>
<td><a href="/lugs/{{ post.categories | default: 'Virtual' }}">{{ post.categories | default: 'Virtual' }}</a></td>
</tr>
{% else %}
<tr><td colspan=6>No LUGS</td></tr>
{% endfor %}
</tbody>
</table>