2010-09-21 05:49:22 +00:00
{% extends "main.html" %}
2010-09-22 18:22:21 +00:00
{% load get_range %}
{% load math %}
2010-09-21 05:49:22 +00:00
{% block title %}Deck: {{ deck.name }}{% endblock %}
{% block content %}
2010-09-17 21:28:46 +00:00
< h2 > {{deck}}< / h2 >
2010-09-23 01:26:21 +00:00
< section class = "mana" >
< h3 > Mana< / h3 >
< section class = "lands" >
< h4 > Lands< / h4 >
< img src = "{{ land_chart.get_url }}" / >
< / section >
< section class = "symbols" >
< h4 > Symbols< / h4 >
< img src = "{{ symbol_chart.get_url }}" / >
< / section >
< section class = "curve" >
< h4 > Curve< / h4 >
< table class = "mana-curve" >
{% for cost, count in curve.items %}
< tr >
< td class = "cost" > {{ cost }}< / td >
< td > < div class = "bar" style = "text-align: right; width: {% widthratio count curve.values|getmax 100 %}%" > {{ count }}< / div > < / td >
< / tr >
{% endfor %}
< / table >
< / section >
< section class = "ramp" >
< h4 > Ramp< / h4 >
< table >
< tr >
< td >
< img src = "{{ ramp_chart.get_url }}" / >
< / td >
< td >
< table >
{% for turn in deck.ramp %}
< tr >
< td > Turn {{ turn.turn }}< / td >
< td > {{ turn.probability }}%< / td >
< / tr >
{% endfor %}
< / table >
< / tr >
< / table >
< / section >
< / section >
< section class = "cards" >
< h3 > Cards< / h3 >
{% regroup deck.included_set.all by card.type as cards %}
< ul >
{% for group in cards %}
< li class = "card-type" > {{ group.grouper|title }}
< ul >
{% for included in group.list %}
< li >
< div class = "card {% if included.card.colors|length > 1 %}gold{% else %}{{ included.card.colors|join:' ' }}{% endif %}" >
< div class = "title" >
< span class = "name" > {{ included.count }}x< / span >
< a class = "name" href = "{% url mtgweb.cards.views.display name=included.card.name %}" > {{ included.card.name }}< / a >
< span class = "cost" > {% with included.card.get_cost as cost %}{% if cost.converted > 0 %}{% include 'cards/manacost.html' %}{% endif %}{% endwith %}< / span >
< / div >
< / div >
< / li >
{% endfor %}
< / ul >
< / li >
{% endfor %}
< / li >
< / section >
2010-09-21 05:49:22 +00:00
{% endblock %}