euscan-ng/euscanwww/djeuscan/templates/euscan/maintainer.html

82 lines
2.4 KiB
HTML
Raw Normal View History

{% extends "euscan/_datatable.html" %}
{% load djeuscan_helpers %}
2012-05-06 20:27:14 +02:00
{% load url from future %}
{% block title %}
{{ block.super }} - Maintainer: {{ maintainer.name }}
{% endblock %}
{% block menu_feed %}
{{ block.super }}
<li>
<img src="{{ STATIC_URL }}/img/feed.png" alt="feed" />
2012-05-06 20:27:14 +02:00
<a title="{{ maintainer.name }} Feed" href="{% url "maintainer_feed" maintainer.id %}">
{{ maintainer.name }}
</a>
</li>
{% endblock %}
{% block content %}
<h2>
Maintainer: {{ maintainer.name }} &lt{{ maintainer.email }}&gt
{% if user.is_authenticated %}
<button class="btn favourite-button {% if favourited %}hide{% endif %}" data-url="{% url "favourite_maintainer" maintainer.id %}">
<img src="{{ STATIC_URL}}/img/watch-icon.png" alt="Watch" >
</button>
<button class="btn unfavourite-button {% if not favourited %}hide{% endif %}" data-url="{% url "unfavourite_maintainer" maintainer.id %}">
<img src="{{ STATIC_URL}}/img/unwatch-icon.png" alt="Unwatch" >
</button>
{% endif %}
</h2>
{% packages packages %}
<h3>Statistics</h2>
<h4>Current statistics</h4>
<p>
2012-05-06 20:27:14 +02:00
<img src="{% url "chart_maintainer" maintainer.id 'pie-versions' %}" />
<img src="{% url "chart_maintainer" maintainer.id 'pie-packages' %}" />
</p>
<h4>All Time</h4>
<p>
2012-05-06 20:27:14 +02:00
<img src="{% url "chart_maintainer" maintainer.id 'versions-weekly' %}" />
<img src="{% url "chart_maintainer" maintainer.id 'versions-monthly' %}" />
</p>
<p>
2012-05-06 20:27:14 +02:00
<img src="{% url "chart_maintainer" maintainer.id 'packages-weekly' %}" />
<img src="{% url "chart_maintainer" maintainer.id 'packages-monthly' %}" />
</p>
<script type="text/javascript">
$(".favourite-button").click(function() {
$.post($(this).data("url"), function() {
$(".unfavourite-button").removeClass("hide");
$(".favourite-button").addClass("hide");
});
});
$(".unfavourite-button").click(function() {
$.post($(this).data("url"), function() {
$(".favourite-button").removeClass("hide");
$(".unfavourite-button").addClass("hide");
});
});
</script>
{% endblock %}
{% block menus %}
{{ block.super }}
<div class="menu rounded notfirst-menu">
<dl>
<dt>Versions</dt>
2012-05-06 20:27:14 +02:00
<dd><img src="{% url "chart_maintainer" maintainer.id 'versions-monthly-small' %}" /></dd>
<dt>Packages</dt>
2012-05-06 20:27:14 +02:00
<dd><img src="{% url "chart_maintainer" maintainer.id 'packages-monthly-small' %}" /></dd>
</dl>
</div>
{% endblock %}