{% extends 'layouts/base.html' %} {% block title %} SRCT Roomlist • Homepage {% endblock %} {% block content %} {% include 'messages.html' %} {% load cache %} {% load gravatar %}

Welcome Back {{ request.user.first_name }}!

{% if not me.room %}

Select your room, and we'll show you the other students on your floor.

{% else %} {% cache 300 roommates request.user.username %} {% if roomies|length == 1 %}

Your Roommate in {{ me.room }}

{% else %}

Your Roommates in {{ me.room }}

{% endif %}
{% for student in roomies %}
{{ student.user.first_name }} Gravatar picture

{{ student.user.get_full_name }}

{{ student.major }}
{% if forloop.counter|divisibleby:4 %}

{% endif %} {% empty %}

There are no other students registered in your room right now.

{% endfor %}
{% endcache %} {% load humanize %} {% cache 300 floormates request.user.username %}

Your Floormates from {{ me.room.floor.building }} {{ me.room.floor.number|ordinal }}

{% for student in floories %}
{{ student.user.first_name }} Gravatar picture

{{ student.user.get_full_name }}

{{ student.major }}
{{ student.room }}
{% if forloop.counter|divisibleby:4 %}

{% endif %} {% empty %}

There are no other students registered on your floor right now.

{% endfor %}
{% endcache %} {% endif %} {% if not me.major %}

Set your major, and we'll show you some of the other students in your program.

{% else %} {% cache 600 majormates request.user.username %}

Other Students in {{ me.major.name }}

{% for student in majormates %}
{{ student.user.first_name }} Gravatar picture

{{ student.user.get_full_name }}

{% if forloop.counter|divisibleby:4 %}

{% endif %} {% empty %}

There are no other students registered in your major right now.

{% endfor %}
{% endcache %} {% endif %} {% endblock %}