mirror of
https://github.com/ae-utbm/sith.git
synced 2024-11-25 10:34:21 +00:00
Sli
655d72a2b1
* Migrate alpine * Migrate jquery and jquery-ui * Migrate shorten * Add babel for javascript * Introduce staticfiles django app * Only bundle -index.js files in static/webpack * Unify scss and webpack generated files * Convert scss calls to static * Add --clear-generated option to collectstatic * Fix docs warnings
58 lines
1.8 KiB
Django/Jinja
58 lines
1.8 KiB
Django/Jinja
{% extends "core/base.jinja" %}
|
|
|
|
{%- block additional_css -%}
|
|
<link rel="stylesheet" href="{{ static('user/user_stats.scss') }}">
|
|
{%- endblock -%}
|
|
|
|
{% block title %}
|
|
{% trans user_name=profile.get_display_name() %}{{ user_name }}'s stats{% endtrans %}
|
|
{% endblock %}
|
|
|
|
{% block content %}
|
|
<div class="container">
|
|
<div class="row">
|
|
{% if profile.permanencies %}
|
|
<div>
|
|
<h3>{% trans %}Permanencies{% endtrans %}</h3>
|
|
<div class="flexed">
|
|
<div><span>Foyer :</span><span>{{ total_foyer_time }}</span></div>
|
|
<div><span>Gommette :</span><span>{{ total_gommette_time }}</span></div>
|
|
<div><span>MDE :</span><span>{{ total_mde_time }}</span></div>
|
|
<div><b>Total :</b><b>{{ total_perm_time }}</b></div>
|
|
</div>
|
|
</div>
|
|
{% endif %}
|
|
|
|
<div>
|
|
<h3>{% trans %}Buyings{% endtrans %}</h3>
|
|
<div class="flexed">
|
|
<div><span>Foyer :</span><span>{{ total_foyer_buyings }} €</span></div>
|
|
<div><span>Gommette :</span><span>{{ total_gommette_buyings }} €</span></div>
|
|
<div><span>MDE :</span><span>{{ total_mde_buyings }} €</span></div>
|
|
<div><b>Total :</b><b>{{ total_foyer_buyings + total_gommette_buyings + total_mde_buyings }} €</b>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div>
|
|
<h3>{% trans %}Product top 10{% endtrans %}</h3>
|
|
<table>
|
|
<thead>
|
|
<tr>
|
|
<td>{% trans %}Product{% endtrans %}</td>
|
|
<td>{% trans %}Quantity{% endtrans %}</td>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{% for p in top_product %}
|
|
<tr>
|
|
<td>{{ p['product__name'] }}</td>
|
|
<td>{{ p['product_sum'] }}</td>
|
|
</tr>
|
|
{% endfor %}
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
{% endblock %} |