Blame view

app/main/templates/agent.html 1.17 KB
d9f5cfc9   hitier   New agent page dy...
1
{% extends "base_page.html" %}
04e2a90d   hitier   Show agent charge...
2
3

{% block more_heads %}
76739351   hitier   Versionize any cu...
4
<link href="{{ url_for('main.static', filename='css/charges.css', version=config.VERSION) }}" rel="stylesheet" type="text/css"/>
04e2a90d   hitier   Show agent charge...
5
6
{% endblock %}

d9f5cfc9   hitier   New agent page dy...
7
{% block content %}
9f86aeea   Anais Amato   Change navbar act...
8
9
10
11

<!-- Invisible span to definte wich ul and a in the navbar are actived -->
<span id="nav_actived" style="display: none">agent,agents</span>

c8b7caf5   hitier   Agent now uses co...
12
<div id="projects_chart" class="charge_chart"></div>
70da5dd5   hitier   Insert charges ta...
13
14
15
16
<table id="charge_table">
  <thead>
  <tr>
  {% for header in charges[0] %}
b9d90810   hitier   Tweak charges tab...
17
    <th>{{header}}</th>
70da5dd5   hitier   Insert charges ta...
18
19
20
21
22
23
  {% endfor %}
  </tr>
  </thead>
  <tbody>
  {% for line in charges[1:] %}
  <tr>
796a5688   hitier   Add % sign in cha...
24
25
    {% for i in range(line|length) %}
      {%if  'Charge' in charges[0][i]  %}
a7537589   hitier   Display charges i...
26
27
        {% set charge = line[i] | int %}
        <td>{{charge / 100}}</td>
796a5688   hitier   Add % sign in cha...
28
29
30
      {%else%}
        <td>{{line[i]}}</td>
      {%endif%}
70da5dd5   hitier   Insert charges ta...
31
32
33
34
35
36
    {% endfor %}
  </tr>
  {% endfor %}

  </tbody>
</table>
d9f5cfc9   hitier   New agent page dy...
37
{% endblock %}
04e2a90d   hitier   Show agent charge...
38
39


d9f5cfc9   hitier   New agent page dy...
40
{% block more_scripts %}
b15e4db5   hitier   Tooltip on mouseo...
41
{% include 'd3js-includes.html' %}
5e6f4e07   hitier   Set Rokotyan Solu...
42
{% include 'charges-includes.html' %}
b15e4db5   hitier   Tooltip on mouseo...
43
<script>
c8b7caf5   hitier   Agent now uses co...
44
45
  build_chart("#projects_chart",
      "{{url_for('main.charge_agent_csv', agent_id=agent.id)}}",
50928b07   hitier   Fix agent name as...
46
      "{{agent.secondname}}"+ " {{agent.firstname}}",
c8b7caf5   hitier   Agent now uses co...
47
      "project");
b15e4db5   hitier   Tooltip on mouseo...
48
</script>
d9f5cfc9   hitier   New agent page dy...
49
{% endblock %}