view templates/profile/user.djhtml @ 80:eaa36eaaf74a

Start integration of new design * New stylesheets, templates, javascript, and images * Added some new template files with filler content for now. * Split up the contents of the static/ directory into img/, js/ and css/ Still in progress. Snippet-posting and -viewing will come soon.
author dellsystem <ilostwaldo@gmail.com>
date Fri, 24 Aug 2012 17:09:07 -0400
parents 349162d0ce19
children eb3371142f4f
line wrap: on
line source

{% extends "whitebox.djhtml" %}

{% block boxtitle %}
{{profile.user.username}} <br/>
{% if profile.user = user %}
<small>
  (<a href="{% url agora.apps.profile.views.editprofile %}">
    edit profile
  </a>)
</small>
{% endif %}
{% endblock boxtitle%}

{% block boxcontents %}
<div id="userinfo">
  {% if profile.user.first_name or profile.user.last_name %}
  <span class="userfield">Name</span>
  <span class="userdata">{{name}}</span>
  <br />
  {% endif %}
  <span class="userfield">Preferred license</span>
  <span class="userdata">{{profile.preferred_license}}</span>
  <br />
  {% if profile.interests %}
  <h4>
    Interests
  </h4>
  <p class="userdata">
    {{profile.interests}}
  </p>
  {% endif %}

  {% if profile.blurb %}
  <h4>
    About {{name}}
  </h4>
  <p class="userdata">
    {{profile.blurb}}
  </p>
</div>
{% endif %}
{% endblock boxcontents %}

{% block content-related %}
{% if bundles or snippets %}
<div id="info">
  <h3>
    Contributions by {{name}}
  </h3>
  <div class="whitebox">
    {% if bundles %}
    <h5>
      Bundles
    </h5>
    <ul>
      {% for b in bundles %}
      <li>
        <a href="{% url agora.apps.bundle.views.detail profile.user b %}">
          {{b.name}}
        </a>
      </li>
      {% endfor %}
    </ul>
    {% endif %}
    {% if snippets %}
    <h5>
      Snippets
    </h5>
    <ul>
      {% for s in snippets %}
      <li><a href="{% url snippet_details s %}">
          {% if s.title %}
          {{s.title}}
          {% else %}
          Snippet #{{s.pk}}
          {% endif %}
      </a></li>
      {% endfor %}
    </ul>
    {% endif %}
  </div>
</div>
{% endif %}
{% endblock content-related %}