pytask/templates/task/browse_textbooks.html
author Madhusudan.C.S <madhusudancs@gmail.com>
Tue, 01 Feb 2011 15:02:52 +0530
changeset 546 6393b77c3c68
parent 497 6386458d749b
permissions -rw-r--r--
Change the textbook list templatetag to task list template tag.

{% extends "base.html" %}


{% load browse_helpers %}


{% block content %}
  {% if aero_textbooks %}
    {% as_list_tasks aero_textbooks "Aerospace Engineering" %}
  {% endif %}

  {% if chemical_textbooks %}
    {% as_list_tasks chemical_textbooks "Chemical Engineering" %}
  {% endif %}

  {% if computerscience_textbooks %}
    {% as_list_tasks computerscience_textbooks "Computer Science and Engineering" %}
  {% endif %}

  {% if electrical_textbooks %}
    {% as_list_tasks electrical_textbooks "Electrical Engineering" %}
  {% endif %}

  {% if engineeringphysics_textbooks %}
    {% as_list_tasks engineeringphysics_textbooks "Engineering Physics Engineering" %}
  {% endif %}

  {% if mechanical_textbooks %}
    {% as_list_tasks mechanical_textbooks "Mechanical Engineering" %}
  {% endif %}

  {% if metallurgical_textbooks %}
    {% as_list_tasks metallurgical_textbooks "Metallurgical Engineering and Materials Science" %}
  {% endif %}





  <!-- TO BE REFORMATTED LATER. JUST PUSHING IT DOWN. -->
  {% comment %}

  {% if comp_textbooks %}
    Textbooks that were completed recently
    <ul>
      {% for textbook in comp_textbooks %}
        <li>
          <a href="{% url view_textbook textbook.id %}">
            {{ textbook.name }}
          </a>
        </li>
      {% endfor %}
    </ul>
    <br />
  {% endif %}

  {% if open_textbooks %}
    Textbooks that are open for contribution
    <ul>
      {% for textbook in open_textbooks %}
        <li>
          <a href="{% url view_textbook textbook.id %}">
            {{ textbook.title }}
          </a>
        </li>
      {% endfor %}
    </ul>
    <br />
  {% endif %}

  {% if unpub_textbooks %}
    Textbooks that need approval
    <ul>
      {% for textbook in unpub_textbooks %}
        <li>
          <a href="{% url view_textbook textbook.id %}">
            {{ textbook.name }}
          </a>
        </li>
      {% endfor %}
    </ul>
  <br />
  {% endif %}
  {% endcomment %}

{% endblock %}