1
Fork 0

Show smallpeice list on robotics page

This commit is contained in:
Jake Howard 2017-11-10 15:10:33 +00:00
parent 8390f95e6b
commit 14e1a8f1d6
Signed by: jake
GPG key ID: 57AFB45680EDD477
3 changed files with 33 additions and 3 deletions

View file

@ -17,6 +17,3 @@ Being at college for 2 years, meant I was able to enter 2 years of competitions,
### Post 2015
Unfortunately, after I left college, I also left behind entering Student Robotics as a competitor. Fortunately however, [they're always looking for volunteers](https://studentrobotics.org/volunteer/) to help run the competition itself, as a _Blue Shirt_. The college kept on working, and keep [their website](http://robotics.collycomp.uk/) updated.
## Smallpeice
[Smallpeice](/robotics/smallpeice) is a competition run in part by members of Student Robotics. It's basically the entire Student Robotics year, compressed into just 5 days! Details on this can be found on the [Smallpeice](/robotics/smallpeice) page.

View file

@ -5,3 +5,4 @@ show_images: true
---
Smallpeice is a compressed version of Student Robotics run by the Smallpeice Trust and University of Southampton. Rather than being run over 6 months like Student Robotics, Smallpeice is run over just 5 days.

View file

@ -0,0 +1,32 @@
{{ define "main" }}
<div id="main">
<div class="container">
{{ partial "content.html" . }}
{{ if .Content }}<hr />{{ end }}
{{ $parent := . }}
{{ $sorted_pages := sort .Site.Pages (default "Title" .Params.sort_by) (default "asc" .Params.sort_order)}}
{{ $valid_pages := where $sorted_pages ".Parent" "!=" nil }}
{{ $valid_pages := where $valid_pages ".Params.hide_in_list" "!=" "true" }}
{{ range where $valid_pages ".Parent.UniqueID" $parent.UniqueID }}
{{ partial "list_item.html" . }}
{{ end }}
{{ if eq .CurrentSection (.Site.GetPage "section" "robotics") }}
<div class="mt-5" />
{{ with .Site.GetPage "section" "robotics/smallpeice"}}
{{ partial "content.html" . }}
<hr />
{{ $parent := . }}
{{ $sorted_pages := sort .Site.Pages (default "Title" .Params.sort_by) (default "asc" .Params.sort_order)}}
{{ $valid_pages := where $sorted_pages ".Parent" "!=" nil }}
{{ $valid_pages := where $valid_pages ".Params.hide_in_list" "!=" "true" }}
{{ range where $valid_pages ".Parent.UniqueID" $parent.UniqueID }}
{{ partial "list_item.html" . }}
{{ end }}
{{ end }}
{{ end }}
</div>
</div>
{{ end }}