fb2df81b7f967b7fa6fd25fbf8b07f772a490f54
[auf_rh_dae.git] / project / rh / templates / rh / rapports / masse_salariale.html
1 {% extends 'rh/rapports/base.html' %}
2 {% load adminmedia rapports i18n l10n %}
3
4 {% block nomrapport %}Rapport de masse salariale{% endblock %}
5 {% block count_elements %}<h2>Rapport année {{ request.GET.annee }}</h2>{% endblock %}
6
7 {% block extrastyle %}
8 {{ block.super }}
9 <style type="text/css">
10 #changelist .actions .filter {width: auto; float: left;}
11 #changelist .actions .filter h3 {font-size: 11px; margin-left: 0.5em;}
12 #result_list .highlighted {background: #ffff88;}
13 </style>
14 {% endblock %}
15
16 {% block extrahead %}
17 {{ block.super }}
18 <script type="text/javascript" src="{{ STATIC_URL }}js/jquery-1.5.1.min.js"></script>
19 <script type="text/javascript" src="{% admin_media_prefix %}js/jquery-stickytableheaders.js"></script>
20 <script type="text/javascript">
21 $(function() {
22 $('#result_list tr').click(function() {
23 $(this).toggleClass('highlighted');
24 });
25 });
26 </script>
27 {% endblock %}
28
29 {% block contentrapport %}
30 {% if url_ods %}
31 <ul class="object-tools">
32 <li>
33 <a href="{{ url_ods }}">Exporter en ods</a>
34 </li>
35 </ul>
36 {% endif %}
37 <form method="GET">
38 <input type="hidden" name="ne_pas_grouper" value="True" />
39 <div class="actions">
40 <div class="filter">
41 <h3>Région</h3>
42 {{ form.region }}
43 </div>
44 <div class="filter">
45 <h3>Implantation</h3>
46 {{ form.implantation }}
47 </div>
48 <div class="filter">
49 <h3>Année</h3>
50 {{ form.annee }}
51 </div>
52 <div class="filter" style="margin-left:20px">
53 <h3>&nbsp;</h3>
54 <button type="submit" class="button" title="Exécuter l'action sélectionnée">Rechercher</button>
55 </div>
56 <div class="clear"></div>
57 {% comment %}
58 <label>Plage de dates:
59 {{ form.date_debut }} au {{ form.date_fin }}
60 </label>
61 {% endcomment %}
62 </div>
63 </form>
64 <div class="clear"></div>
65
66
67 <script type="text/javascript">
68 jQuery(document).ready(function(){
69 $("#result_list").stickyTableHeaders();
70 });
71 </script>
72 <table id="result_list" class="results">
73 <thead>
74 <tr>
75 {% table_header headers %}
76 </tr>
77 </thead>
78 {% localize on %}
79 {% spaceless %}
80 {% for row in rapport %}
81 <tr class="{% cycle 'row1' 'row2' %}">
82 {% for column in header_keys %}
83 {% if column == 'sep' %}
84 <td style="background:gray;">&nbsp;</td>
85 {% else %}
86 {% if row|hash:column|is_float %}
87 <td>
88 {% comment %}
89 {% if options.backgroundcolor %}
90 style="background-color:{{ options.backgroundcolor }}"
91 {% endif %}
92 {% endcomment %}
93 {{ row|hash:column|floatformat:2|localize }}
94 {% if column != "point" %}
95 {% if forloop.last or column|contains:"euro" %}
96 EUR
97 {% else %}
98 {{ row.devise }}
99 {% endif %}
100 {% endif %}
101 </td>
102 {% else %}
103 <td>{{ row|hash:column|default:"" }}</td>
104 {% endif %}
105 {% endif %}
106 {% endfor %}
107 </tr>
108 {% endfor %}{% endspaceless %}
109 <tr>
110 <td colspan="{{ colspan }}" style="text-align:right;font-weight:bold;">
111 TOTAL :
112 </td>
113 <td>{{ total_euro }}</td>
114 </tr>
115 </table>
116 {% endlocalize %}
117 {% endblock %}