Skip to content

Commit 971a631

Browse files
committed
Fix django 1.7 deprecation warnings: quote arguments to the 'cycle' template tag.
- Legacy-Id: 8826
1 parent a0ceff3 commit 971a631

18 files changed

Lines changed: 71 additions & 49 deletions

ietf/templates/community/manage_clist.html

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
1+
{# Copyright The IETF Trust 2007, All Rights Reserved #}
12
{% extends "base.html" %}
3+
{% load future %}
24

35
{% block title %}{{ cl.long_name }}{% endblock %}
46

@@ -35,7 +37,7 @@ <h2>Documents explicitly included, from a document search.</a></h2>
3537
<table class="ietf-table">
3638
<tr><th>Name</th><th>State</th><th>Title</th><th>Remove from list</th></tr>
3739
{% for doc in cl.added_ids.all %}
38-
<tr class="{% cycle oddrow,evenrow %}">
40+
<tr class="{% cycle 'oddrow','evenrow' %}">
3941
<td>{{ doc.display_name }}</td>
4042
<td>{{ doc.get_state }}</td>
4143
<td><a href="{{ doc.get_absolute_url }}"</a>{{ doc.title }}</td>
@@ -51,7 +53,7 @@ <h2>Rules added to this list</h2>
5153
<tr><th>Rule</th><th>Value</th><th>Documents</th><th>Remove from list</th></tr>
5254
{% for rule in cl.rule_set.all %}
5355
{% with rule.get_callable_rule as callable %}
54-
<tr class="{% cycle oddrow,evenrow %}">
56+
<tr class="{% cycle 'oddrow','evenrow' %}">
5557
<td>{{ callable.description }}</td>
5658
<td>{{ callable.show_value }}</td>
5759
<td>{% with rule.cached_ids.count as count %}{{ count }} document{{ count|pluralize }}{% endwith %}</td>

ietf/templates/community/raw_view.html

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
1+
{# Copyright The IETF Trust 2007, All Rights Reserved #}
12
{% load community_tags %}
3+
{% load future %}
24

35
{% with cl.get_rfcs_and_drafts as documents %}
46
{% with dc.get_active_fields as fields %}
@@ -10,7 +12,7 @@ <h2>Drafts</h2>
1012
{% endfor %}
1113
</tr>
1214
{% for doc in documents.1 %}
13-
<tr class="{% cycle oddrow,evenrow %}">
15+
<tr class="{% cycle 'oddrow','evenrow' %}">
1416
{% for field in fields %}
1517
<td>
1618
{% show_field field doc %}
@@ -30,7 +32,7 @@ <h2>RFCs</h2>
3032
{% endfor %}
3133
</tr>
3234
{% for doc in documents.0 %}
33-
<tr class="{% cycle oddrow,evenrow %}">
35+
<tr class="{% cycle 'oddrow','evenrow' %}">
3436
{% for field in fields %}
3537
<td>
3638
{% show_field field doc %}

ietf/templates/debug.html

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
{# Copyright The IETF Trust 2007, All Rights Reserved #}
22
{% if debug %}
33
{% load ietf_filters %}
4+
{% load future %}
5+
46
<div id="debug" style="clear: left;">
57
<h2>Queries</h2>
68
<p>
@@ -22,7 +24,7 @@ <h2>Queries</h2>
2224
</thead>
2325
<tbody>
2426
{% for query in sql_queries %}
25-
<tr class="{% cycle odd,even %}">
27+
<tr class="{% cycle 'odd','even' %}">
2628
<td>{{ forloop.counter }}</td>
2729
<td>{{ query.sql|expand_comma|escape }}</td>
2830
<td>{{ query.time }}</td>

ietf/templates/doc/document_history.html

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
1+
{# Copyright The IETF Trust 2007, All Rights Reserved #}
12
{% extends "base.html" %}
2-
33
{% load ietf_filters %}
4+
{% load future %}
45

56
{% block title %}History for {{ doc.name }}-{{ doc.rev }}{% endblock %}
67

@@ -65,7 +66,7 @@ <h2>Document history</h2>
6566
<tr><th>Date</th><th>Version</th><th>By</th><th>Text</th></tr>
6667

6768
{% for e in events %}
68-
<tr class="{% cycle oddrow,evenrow %}" id="history-{{ e.pk }}">
69+
<tr class="{% cycle 'oddrow','evenrow' %}" id="history-{{ e.pk }}">
6970
<td>{{ e.time|date:"Y-m-d" }}</td>
7071
<td>{{ e.rev }}</td>
7172
<td>{{ e.by }}</td>

ietf/templates/group/history.html

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
1+
{# Copyright The IETF Trust 2007, All Rights Reserved #}
12
{% extends "group/group_base.html" %}
23
{% load ietf_filters %}
4+
{% load future %}
35

46
{% block group_subtitle %}History{% endblock %}
57

@@ -12,7 +14,7 @@ <h2>Group History</h2>
1214
<tr><th>Date</th><th>By</th><th>Text</th></tr>
1315

1416
{% for e in events %}
15-
<tr class="{% cycle oddrow,evenrow %}">
17+
<tr class="{% cycle 'oddrow','evenrow' %}">
1618
<td>{{ e.time|date:"Y-m-d"}}</td>
1719
<td>{{ e.by.plain_name }}</td>
1820
<td>{{ e.desc|format_history_text }}</td>

ietf/templates/help/index.html

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
1-
{% extends "base.html" %}
21
{# Copyright The IETF Trust 2007, All Rights Reserved #}
2+
{% extends "base.html" %}
3+
{% load future %}
34

45
{% block title %} Document State Index{% endblock %}
56

@@ -17,7 +18,7 @@ <h1>Document State Index</h1>
1718

1819
{% for type in types %}
1920
{% if type.stategroups != None %}
20-
<tr class="{% cycle oddrow,evenrow as cycle1 %}">
21+
<tr class="{% cycle 'oddrow','evenrow' as cycle1 %}">
2122
<td><a href='{{ type.slug }}/'>{{type.slug}}</td>
2223
<td>
2324
{% for group in type.stategroups %}

ietf/templates/help/states.html

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
1-
{% extends "base.html" %}
21
{# Copyright The IETF Trust 2007, All Rights Reserved #}
2+
{% extends "base.html" %}
3+
{% load future %}
34

45
{% block title %} {{type.label|cut:"state"|cut:"State"}} Statess{% endblock %}
56

@@ -16,7 +17,7 @@ <h1>{{type.label|cut:"state"|cut:"State"}} States</h1>
1617
</tr>
1718

1819
{% for state in states %}
19-
<tr class="{% cycle oddrow,evenrow as cycle1 %}">
20+
<tr class="{% cycle 'oddrow','evenrow' as cycle1 %}">
2021
<td>{{ state.name }}</td>
2122
<td>{{ state.desc|safe }}</td>
2223
<td><ul>{% for s in state.next_states.all %}<li>{{ s.name }}</li>{%endfor%}</ul></td>

ietf/templates/ipr/details.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
{% autoescape off %}{% load ietf_filters %}{% load ipr_filters %}IPR Title: {{ ipr.title|safe }}
1+
{% autoescape off %}{% load ietf_filters %}{% load ipr_filters %}{% load future %}IPR Title: {{ ipr.title|safe }}
22

3-
Section {% cycle I,II,III,IV,V,VI,VII,VIII as section %}. {% if ipr|to_class_name == "ThirdPartyIprDisclosure" %}Possible {% endif %}Patent Holder/Applicant ("Patent Holder")
3+
Section {% cycle 'I','II','III','IV','V','VI','VII','VIII' as section %}. {% if ipr|to_class_name == "ThirdPartyIprDisclosure" %}Possible {% endif %}Patent Holder/Applicant ("Patent Holder")
44
Legal Name: {{ ipr.holder_legal_name|safe }}
55

66

ietf/templates/ipr/details_edit.html

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
{% extends "base.html" %}
21
{# Copyright The IETF Trust 2007, All Rights Reserved #}
3-
2+
{% extends "base.html" %}
43
{% load ietf_filters %}
54
{% load ipr_filters %}
5+
{% load future %}
66

77
{% block title %}New IPR - Form{% endblock %}
88

@@ -78,7 +78,7 @@ <h1>The Patent Disclosure and Licensing Declaration Template for Generic IPR Dis
7878
<p class="formlegend">Fields marked with "*" are required.</p>
7979

8080
<table class="ipr">
81-
<tr class="{% cycle dark,light as row_parity %}"><th colspan=2>Updates</th></tr>
81+
<tr class="{% cycle 'dark','light' as row_parity %}"><th colspan=2>Updates</th></tr>
8282
<tr class="{% cycle row_parity %}"><td colspan=2>If this disclosure <b>updates</b> another disclosure(s) identify here which one(s).
8383
Leave this field blank if this disclosure does not update any prior disclosures.
8484
Note: Updates to IPR disclosures must only be made by authorized
@@ -103,9 +103,9 @@ <h1>The Patent Disclosure and Licensing Declaration Template for Generic IPR Dis
103103
<br>
104104

105105
<table class="ipr">
106-
<tr class="{% cycle dark,light as row_parity %}">
106+
<tr class="{% cycle 'dark','light' as row_parity %}">
107107
<th colspan=2>
108-
{% cycle I,II,III,IV,V,VI,VII,VIII as section %}.
108+
{% cycle 'I','II','III','IV','V','VI','VII','VIII' as section %}.
109109
{% if form.instance|to_class_name == "ThirdPartyIprDisclosure" %}Possible{% endif %}
110110
Patent Holder/Applicant ("Patent Holder")
111111
</th>
@@ -117,7 +117,7 @@ <h1>The Patent Disclosure and Licensing Declaration Template for Generic IPR Dis
117117

118118
{% if form.holder_contact_name %}
119119
<table class="ipr">
120-
<tr class="{% cycle dark,light as row_parity %}">
120+
<tr class="{% cycle 'dark','light' as row_parity %}">
121121
<th colspan="2">
122122
{% cycle section %}.
123123
Patent Holder's Contact for License Application
@@ -131,7 +131,7 @@ <h1>The Patent Disclosure and Licensing Declaration Template for Generic IPR Dis
131131

132132
{% if form.ietfer_name %}
133133
<table class="ipr">
134-
<tr class="{% cycle dark,light as row_parity %}">
134+
<tr class="{% cycle 'dark','light' as row_parity %}">
135135
<th colspan="2" >
136136
{% cycle section %}.
137137
Contact Information for the IETF Participant Whose Personal Belief Triggered this Disclosure:
@@ -151,7 +151,7 @@ <h1>The Patent Disclosure and Licensing Declaration Template for Generic IPR Dis
151151
<col width="15%">
152152
<col width="15%">
153153

154-
<tr class="{% cycle dark,light as row_parity %}">
154+
<tr class="{% cycle 'dark','light' as row_parity %}">
155155
<th colspan="4" >
156156
<span class="required">*</span>
157157
{% cycle section %}.
@@ -192,7 +192,7 @@ <h1>The Patent Disclosure and Licensing Declaration Template for Generic IPR Dis
192192

193193
<!-- Begin Patent Section -->
194194
<table class="ipr">
195-
<tr class="{% cycle dark,light as row_parity %}">
195+
<tr class="{% cycle 'dark','light' as row_parity %}">
196196
<th colspan="2" >
197197
{% cycle section %}.
198198
Disclosure of Patent Information{% if form.instance|to_class_name == "ThirdPartyIprDicslosure" %}, if known{% endif %} (i.e., patents or
@@ -228,7 +228,7 @@ <h1>The Patent Disclosure and Licensing Declaration Template for Generic IPR Dis
228228
{% if form.licensing %}
229229
<!-- Not to be shown for third-party disclosures -->
230230
<table class="ipr">
231-
<tr class="{% cycle dark,light as row_parity %}">
231+
<tr class="{% cycle 'dark','light' as row_parity %}">
232232
<th colspan="2" >
233233
{% cycle section %}.
234234
Licensing Declaration
@@ -302,7 +302,7 @@ <h1>The Patent Disclosure and Licensing Declaration Template for Generic IPR Dis
302302

303303
{% if form.statement %}
304304
<table class="ipr">
305-
<tr class="{% cycle dark,light as row_parity %}">
305+
<tr class="{% cycle 'dark','light' as row_parity %}">
306306
<th colspan="2" >
307307
{% cycle section %}.
308308
Statement
@@ -325,7 +325,7 @@ <h1>The Patent Disclosure and Licensing Declaration Template for Generic IPR Dis
325325
{% endif %} <!-- form.statement (Generic and NonDocSpecific) -->
326326

327327
<table class="ipr">
328-
<tr class="{% cycle dark,light as row_parity %}">
328+
<tr class="{% cycle 'dark','light' as row_parity %}">
329329
<th colspan="2" >
330330
{% cycle section %}.
331331
Contact Information of Submitter of this Form (if different from the Contact Information above)
@@ -337,7 +337,7 @@ <h1>The Patent Disclosure and Licensing Declaration Template for Generic IPR Dis
337337
</table>
338338

339339
<table class="ipr">
340-
<tr class="{% cycle dark,light as row_parity %}">
340+
<tr class="{% cycle 'dark','light' as row_parity %}">
341341
<th colspan="2" >
342342
{% cycle section %}.
343343
Other Notes:

ietf/templates/ipr/details_history.html

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
{% extends "ipr/details_base.html" %}
21
{# Copyright The IETF Trust 2007, All Rights Reserved #}
3-
2+
{% extends "ipr/details_base.html" %}
43
{% load ietf_filters %}
54
{% load ipr_filters %}
5+
{% load future %}
66

77
{% block pagehead %}
88
<link rel="stylesheet" type="text/css" href="/css/ipr.css"></link>
@@ -23,7 +23,7 @@ <h2>Disclosure history</h2>
2323
<tr><th class="date-column">Date</th><th>Type</th><th>By</th><th>Text</th></tr>
2424

2525
{% for e in events %}
26-
<tr class="{% cycle oddrow,evenrow %}" id="history-{{ e.pk }}">
26+
<tr class="{% cycle 'oddrow','evenrow' %}" id="history-{{ e.pk }}">
2727
<td class="date-column">{{ e.time|date:"Y-m-d" }}</td>
2828
<td>{{ e.type }}
2929
{% if e.response_due %}

0 commit comments

Comments
 (0)