~speakman/ppvalbok/trunk

« back to all changes in this revision

Viewing changes to templates/view_municipality.html

  • Committer: Daniel Nyström
  • Date: 2009-05-24 21:35:17 UTC
  • Revision ID: daniel@nystrom.st-20090524213517-q6d1t2d235k5wugu
MAJOR VotingLocal refactoring

Show diffs side-by-side

added added

removed removed

Lines of Context:
4
4
{% endblock %}
5
5
 
6
6
{% block title %}Vallokaler för {{ municipality_name }}{% endblock%}
 
7
{% block style %}<link rel="stylesheet" type="text/css" href="{{ MEDIA_URL }}css/municipality.css" />{% endblock %}
7
8
 
8
9
{% block content %}
9
10
<h1>Vallokaler för {{ municipality_name }}</h1>
35
36
                <h3>Förtidsröstningslokaler, öppnar 20 maj</h3>
36
37
                {% if early_stations %}
37
38
                {% for station in early_stations %}
38
 
                <div id="evs_{{ station.code }}" class="stationentry {% if station.evsdata.get_booking %}full_{% else %}unbooked_{% endif %}station">
39
 
                        {% if station.evsdata.get_booking %}
40
 
                        <img src="{{MEDIA_URL}}images/green_check.png" 
41
 
                         alt="R&ouml;stningslokalen &auml;r bokad" 
42
 
                         title="R&ouml;stningslokalen &auml;r bokad" />
43
 
                        {% else %}
44
 
                        <img src="{{MEDIA_URL}}images/red_cross.png"
45
 
                         alt="R&ouml;stningslokalen &auml;r inte bokad"
46
 
                         title="R&ouml;stningslokalen &auml;r inte bokad" />
47
 
                        {% endif %}
48
 
                        {% if station.name %}
49
 
                        <a href="{% url earlystation station.municipality.slug station.slug %}">{{ station.name }}</a>
50
 
                        {% else %}
51
 
                        <i>Uppgifter saknas om denna lokal</i>
52
 
                        {% endif %}
53
 
                </div>
 
39
                <table id="evs_{{ station.code }}" class="stationentry {% if station.evsdata.get_booking %}full_{% else %}unbooked_{% endif %}station">
 
40
                        <tr>
 
41
                                <td class="evstatus">
 
42
                                        {% if station.evsdata.get_booking %}
 
43
                                        <img src="{{MEDIA_URL}}images/green_check.png" 
 
44
                                             alt="R&ouml;stningslokalen &auml;r bokad" 
 
45
                                             title="R&ouml;stningslokalen &auml;r bokad" />
 
46
                                        {% else %}
 
47
                                        <img src="{{MEDIA_URL}}images/red_cross.png"
 
48
                                             alt="R&ouml;stningslokalen &auml;r inte bokad"
 
49
                                             title="R&ouml;stningslokalen &auml;r inte bokad" />
 
50
                                        {% endif %}
 
51
                                </td>
 
52
                                <td>
 
53
                                        <a href="{% url earlystation station.municipality.slug station.slug %}">{{ station.name }}</a>
 
54
                                        <p class="extrainfo">{{ station.get_full_address }}</p>
 
55
                                </td>
 
56
                        </tr>
 
57
                </table>
54
58
                {% endfor %}
55
59
                {% else %}
56
60
        <i>Inga förtidsröstningslokaler i {{ municipality_name }}.</i>
59
63
        <div id="stationlist">
60
64
                <h3>Vallokaler, 7 juni</h3>
61
65
                {% for station in stations %}
62
 
                <a name="vs_{{ station.code }}" />
63
 
                <div id="vs_{{ station.code }}" class="stationentry {% if station.vsdata.get_booking_0 %}{% if station.vsdata.get_booking_1 and station.vsdata.get_booking_2 and station.vsdata.get_booking_3 %}full_{% else %}booked_{% endif %}{% else %}unbooked_{% endif %}station {% if station.hidden %}hidden{% endif %}">
64
 
 
65
 
                        {% if station.vsdata.get_booking_0 %}
66
 
                        <img src="{{MEDIA_URL}}images/green_check.png" 
67
 
                         alt="Distributörsrollen är bokad{% if may_edit %} av {{ station.vsdata.distributor.email }}{% endif %}" 
68
 
                         title="Distributörsrollen är bokad{% if may_edit %} av {{ station.vsdata.distributor.email }}{% endif %}" />
69
 
                        {% else %}
70
 
                        <img src="{{MEDIA_URL}}images/red_cross.png"
71
 
                         alt="Distributörsrollen är inte bokad"
72
 
                         title="Distributörsrollen är inte bokad" />
73
 
                        {% endif %}
74
 
 
75
 
                        {% if station.vsdata.get_booking_1 %}
76
 
                        <img src="{{MEDIA_URL}}images/green_check_small.png" 
77
 
                         alt="F&ouml;rsta passet &auml;r bokat{% if may_edit %} av {{ station.vsdata.first_watch.email }}{% endif %}" 
78
 
                         title="F&ouml;rsta passet &auml;r bokat{% if may_edit %} av {{ station.vsdata.first_watch.email }}{% endif %}" />
79
 
                        {% else %}
80
 
                        <img src="{{MEDIA_URL}}images/red_cross_small.png"
81
 
                         alt="F&ouml;rsta passet &auml;r inte bokat"
82
 
                         title="F&ouml;rsta passet &auml;r inte bokat" />
83
 
                        {% endif %}
84
 
 
85
 
                        {% if station.vsdata.get_booking_2 %}
86
 
                        <img src="{{MEDIA_URL}}images/green_check_small.png" 
87
 
                         alt="Andra passet &auml;r bokat{% if may_edit %} av {{ station.vsdata.second_watch.email }}{% endif %}" 
88
 
                         title="Andra passet &auml;r bokat{% if may_edit %} av {{ station.vsdata.second_watch.email }}{% endif %}" />
89
 
                        {% else %}
90
 
                        <img src="{{MEDIA_URL}}images/red_cross_small.png"
91
 
                         alt="Andra passet &auml;r inte bokat"
92
 
                         title="Andra passet &auml;r inte bokat" />
93
 
                        {% endif %}
94
 
 
95
 
                        {% if station.vsdata.get_booking_3 %}
96
 
                        <img src="{{MEDIA_URL}}images/green_check_small.png" 
97
 
                         alt="Tredje passet &auml;r bokat{% if may_edit %} av {{ station.vsdata.third_watch.email }}{% endif %}" 
98
 
                         title="Tredje passet &auml;r bokat{% if may_edit %} av {{ station.vsdata.third_watch.email }}{% endif %}" />
99
 
                        {% else %}
100
 
                        <img src="{{MEDIA_URL}}images/red_cross_small.png"
101
 
                         alt="Tredje passet &auml;r inte bokat"
102
 
                         title="Tredje passet &auml;r inte bokat" />
103
 
                        {% endif %}
104
 
 
105
 
                        <a href="{% url votingstation station.municipality.slug station.slug %}">{{ station.local }}</a>{% if show_all %} {{ station.name }}{% endif %}<br />
106
 
                        {% if show_all %}{{ station.city }}{% endif %}
107
 
                </div>
 
66
                <a name="vs_{{ station.code }}"></a>
 
67
                <table id="vs_{{ station.code }}" class="stationentry {% if station.vsdata.get_booking_0 %}{% if station.vsdata.get_booking_1 and station.vsdata.get_booking_2 and station.vsdata.get_booking_3 %}full_{% else %}booked_{% endif %}{% else %}unbooked_{% endif %}station {% if station.hidden %}hidden{% endif %}">
 
68
                        <tr>
 
69
                                <td class="status">
 
70
                                        {% if station.vsdata.get_booking_0 %}
 
71
                                        <img src="{{MEDIA_URL}}images/green_check.png" 
 
72
                                             alt="Distributörsrollen är bokad{% if may_edit %} av {{ station.vsdata.distributor.email }}{% endif %}" 
 
73
                                             title="Distributörsrollen är bokad{% if may_edit %} av {{ station.vsdata.distributor.email }}{% endif %}" />
 
74
                                        {% else %}
 
75
                                        <img src="{{MEDIA_URL}}images/red_cross.png"
 
76
                                             alt="Distributörsrollen är inte bokad"
 
77
                                             title="Distributörsrollen är inte bokad" />
 
78
                                        {% endif %}
 
79
                                        
 
80
                                        {% if station.vsdata.get_booking_1 %}
 
81
                                        <img src="{{MEDIA_URL}}images/green_check_small.png" 
 
82
                                             alt="F&ouml;rsta passet &auml;r bokat{% if may_edit %} av {{ station.vsdata.first_watch.email }}{% endif %}" 
 
83
                                             title="F&ouml;rsta passet &auml;r bokat{% if may_edit %} av {{ station.vsdata.first_watch.email }}{% endif %}" />
 
84
                                        {% else %}
 
85
                                        <img src="{{MEDIA_URL}}images/red_cross_small.png"
 
86
                                             alt="F&ouml;rsta passet &auml;r inte bokat"
 
87
                                             title="F&ouml;rsta passet &auml;r inte bokat" />
 
88
                                        {% endif %}
 
89
                                        
 
90
                                        {% if station.vsdata.get_booking_2 %}
 
91
                                        <img src="{{MEDIA_URL}}images/green_check_small.png" 
 
92
                                             alt="Andra passet &auml;r bokat{% if may_edit %} av {{ station.vsdata.second_watch.email }}{% endif %}" 
 
93
                                             title="Andra passet &auml;r bokat{% if may_edit %} av {{ station.vsdata.second_watch.email }}{% endif %}" />
 
94
                                        {% else %}
 
95
                                        <img src="{{MEDIA_URL}}images/red_cross_small.png"
 
96
                                             alt="Andra passet &auml;r inte bokat"
 
97
                                             title="Andra passet &auml;r inte bokat" />
 
98
                                        {% endif %}
 
99
                                        
 
100
                                        {% if station.vsdata.get_booking_3 %}
 
101
                                        <img src="{{MEDIA_URL}}images/green_check_small.png" 
 
102
                                             alt="Tredje passet &auml;r bokat{% if may_edit %} av {{ station.vsdata.third_watch.email }}{% endif %}" 
 
103
                                             title="Tredje passet &auml;r bokat{% if may_edit %} av {{ station.vsdata.third_watch.email }}{% endif %}" />
 
104
                                        {% else %}
 
105
                                        <img src="{{MEDIA_URL}}images/red_cross_small.png"
 
106
                                             alt="Tredje passet &auml;r inte bokat"
 
107
                                             title="Tredje passet &auml;r inte bokat" />
 
108
                                        {% endif %}
 
109
                                        </td>
 
110
                                <td>
 
111
                                        <a href="{% url votingstation station.municipality.slug station.slug %}">{{ station.name }}</a>
 
112
                                        <br />
 
113
                                        <p class="extrainfo">{{ station.get_full_address }}</p>
 
114
                                </td>
 
115
                        </tr>
 
116
                </table>
108
117
                {% endfor %}
109
118
        </div>
110
119
</div>