Skip to content

Commit

Permalink
change templates
Browse files Browse the repository at this point in the history
  • Loading branch information
zodman committed Feb 15, 2011
1 parent 9269237 commit c040407
Show file tree
Hide file tree
Showing 3 changed files with 95 additions and 0 deletions.
40 changes: 40 additions & 0 deletions portfolio/templates/portfolio/index.html
@@ -0,0 +1,40 @@
{% load i18n cms_tags portafolio_menu thumbnail %}
{% block menu_casos %}
{% portafolio_menu_client proyect %}
{% endblock %}

<div>
<ul>
{% for i in proyect.images.all|dictsort:'sequence' %}
<li >
<a href="#">
{% thumbnail i.image "360x194" crop="center" as img %}
<img border="0" width="{{ img.width }}" height="{{ img.height }}" alt="" src="{{img.url }}">
{% endthumbnail %}
</a>
</li>
{%endfor%}
</ul>
</div>
<div>
<h2>{{ proyect.service.name }}</h2>
<h1>{{proyect.name}}</h1>
<h3>{{ proyect.country.name }}</h3>
<p>
{{proyect.description_short|safe }}
<p>
{{proyect.description_long|safe }}
</p>
<a href="{{proyect.url}}" target="_blank">{{proyect.get_url}}</a>
</div>
<div id="socialesCasos">
<p>
{% if proyect.twitter%}
<a href="http://twitter.com/share" class="twitter-share-button" data-count="horizontal" data-via={{proyect.twitter}}"" data-related="{{ proyect.name }}" data-lang="en">Tweet</a><script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script>
{% endif %}
</p>
{%if proyect.facebook_like%}
<script src="http://connect.facebook.net/es_LA/all.js#xfbml=1"></script><fb:like href="{{ proyect.facebook_like }}" show_faces="false" id="megusta" width="120" layout="button_count" ></fb:like>
{% endif %}

</div>
25 changes: 25 additions & 0 deletions portfolio/templates/portfolio/menu.html
@@ -0,0 +1,25 @@
<div class="leftColCasos">
<div id="menuCasosContainer">
<nav id="navigationContainer">
<ul id="navigation">
{% for c in portafolio_clients %}
<li>
{% with c.proyects.count as count %}
<a class="{%if c > 0 %}head{%else%}headSinSubMenu{%endif%}" href="javascript:void(0);">{{c.name}}</a>
{%if c > 0 %}
<ul>
{% for p in c.proyects.all %}
<li><a class="{% if p == actual%}current{% endif %}" href="{% url portafolio-proyect p.slug %}">{{p.name}}</a></li>
{% empty%}
<li></li>
{% endfor%}
</ul>
{% endif %}
{% endwith %}
</li>
{% endfor %}
</ul>
</nav><!--navigationContainer -->
</div><!--menuCasosContainer -->
</div><!--leftColCasos -->

30 changes: 30 additions & 0 deletions portfolio/templates/portfolio/portfolio.html
@@ -0,0 +1,30 @@
{% load thumbnail %}

{% for p in instance.portafolio.all|dictsort:"sequence" %}
<a href="{% url portafolio-proyect p.slug %}">
<div class="moduloFoto">
{% for image in p.images.all %}
{%if image.main %}
{% thumbnail image.image "180x97" crop="center" as img %}
<a href="{# url portafolio-proyect p.slug #}">
<img border="0" src="{{ img.url }}" width="{{ img.width }}" height="{{img.height }}" title="Proyecto" />
</a>
{% endthumbnail %}
{% endif %}
{% endfor %}
</div>
<div id="moduloTexto">
<h2>{{p.service.name}}</h2>
<h1><a href="{# url portafolio-proyect p.slug #}">{{p.name}}</a></h1>
<h3>{{p.country.name}}</h3>
{% spaceless%}
<p class="liga">
<a href="{# url portafolio-proyect p.slug #}">

{{p.description_short|striptags|linebreaksbr|truncatewords:"29" }}
</a>
</p>
{% endspaceless%}
</div>
</a>
{% endfor %}

0 comments on commit c040407

Please sign in to comment.