Skip to content

Commit b167031

Browse files
committed
Merged in [18886] from rjsparks@nostrum.com:
Change ipr pages to say General rather than Generic, and to change the text to note email submissions are not accepted. Fixes ietf-tools#3209. - Legacy-Id: 18888 Note: SVN reference [18886] has been migrated to Git commit 550c123
2 parents ae67fc0 + 550c123 commit b167031

7 files changed

Lines changed: 43 additions & 14 deletions

File tree

ietf/ipr/forms.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,7 @@ def clean(self):
233233
for k in patent_fields:
234234
if not cleaned_data.get(k):
235235
self.add_error(k, "This field is required if you are filing a patent-specific disclosure.")
236-
raise forms.ValidationError("A generic IPR disclosure cannot have any patent-specific information, "
236+
raise forms.ValidationError("A general IPR disclosure cannot have any patent-specific information, "
237237
"but a patent-specific disclosure must provide full patent information.")
238238

239239
patent_fields += ['patent_notes']

ietf/ipr/tests.py

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77

88
from pyquery import PyQuery
9-
from urllib.parse import quote
9+
from urllib.parse import quote, urlparse
1010

1111
from django.urls import reverse as urlreverse
1212

@@ -208,9 +208,17 @@ def test_sitemap(self):
208208
self.assertContains(r, "/ipr/%s/" % ipr.pk)
209209

210210
def test_new_generic(self):
211-
"""Add a new generic disclosure. Note: submitter does not need to be logged in.
212-
"""
211+
"""Ensure new-generic redirects to new-general"""
213212
url = urlreverse("ietf.ipr.views.new", kwargs={ "type": "generic" })
213+
r = self.client.get(url)
214+
self.assertEqual(r.status_code,302)
215+
self.assertEqual(urlparse(r["Location"]).path, urlreverse("ietf.ipr.views.new", kwargs={ "type": "general"}))
216+
217+
218+
def test_new_general(self):
219+
"""Add a new general disclosure. Note: submitter does not need to be logged in.
220+
"""
221+
url = urlreverse("ietf.ipr.views.new", kwargs={ "type": "general" })
214222

215223
# invalid post
216224
r = self.client.post(url, {

ietf/ipr/urls.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,6 @@
2525
url(r'^(?P<id>\d+)/state/$', views.state),
2626
url(r'^update/$', RedirectView.as_view(url=reverse_lazy('ietf.ipr.views.showlist'), permanent=True)),
2727
url(r'^update/(?P<id>\d+)/$', views.update),
28-
url(r'^new-(?P<type>(specific|generic|third-party))/$', views.new),
28+
url(r'^new-(?P<type>(specific|generic|general|third-party))/$', views.new),
2929
url(r'^search/$', views.search),
3030
]

ietf/ipr/views.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -484,6 +484,18 @@ def by_draft_recursive_txt(request):
484484
def new(request, type, updates=None):
485485
"""Submit a new IPR Disclosure. If the updates field != None, this disclosure
486486
updates one or more other disclosures."""
487+
# Note that URL patterns won't ever send updates - updates is only non-null when called from code
488+
489+
# This odd construct flipping generic and general allows the URLs to say 'general' while having a minimal impact on the code.
490+
# A cleanup to change the code to switch on type 'general' should follow.
491+
if type == 'generic' and updates: # Only happens when called directly from the updates view
492+
pass
493+
elif type == 'generic':
494+
return HttpResponseRedirect(urlreverse('ietf.ipr.views.new',kwargs=dict(type='general')))
495+
elif type == 'general':
496+
type = 'generic'
497+
else:
498+
pass
487499

488500
# 1 to show initially + the template
489501
DraftFormset = inlineformset_factory(IprDisclosureBase, IprDocRel, form=DraftForm, can_delete=False, extra=1 + 1)

ietf/templates/ipr/details_edit.html

Lines changed: 15 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ <h1>The Patent Disclosure and Licensing Declaration Template for Third Party IPR
3737
patent applicants.</p>
3838

3939
{% else %}
40-
<h1>The Patent Disclosure and Licensing Declaration Template for Generic IPR Disclosures</h1>
40+
<h1>The Patent Disclosure and Licensing Declaration Template for General IPR Disclosures</h1>
4141
<p>This document is an IETF IPR Patent Disclosure and Licensing
4242
Declaration Template and is submitted to inform the IETF of a) patent
4343
or patent application information that is not related to a specific
@@ -49,18 +49,27 @@ <h1>The Patent Disclosure and Licensing Declaration Template for Generic IPR Dis
4949
<a href="https://www.ietf.org/rfc/rfc8179.txt">RFC 8179</a>,
5050
"Intellectual Property Rights in IETF Technology," you
5151
are still required to file specific disclosures on IPR unless your
52-
generic disclosure satisfies certain conditions. Please see the
52+
general disclosure satisfies certain conditions. Please see the
5353
RFC for details.</p>
5454
{% endif %}
5555

5656
<p>
57-
If you wish to submit your IPR disclosure by e-mail, then please send
58-
it to <a href="mailto:ietf-ipr@ietf.org">ietf-ipr@ietf.org</a>.
59-
Submissions made by e-mail that do not comply with the formal
57+
Submissions that do not comply with the formal
6058
requirements of Section 5, "IPR Disclosures," of
6159
<a href="https://www.ietf.org/rfc/rfc8179.txt">RFC 8179</a>,
6260
"Intellectual Property Rights in IETF Technology",
63-
will be posted, but will be marked as "non-compliant".
61+
may be
62+
{% if form.instance|to_class_name != "GenericIprDisclosure" %}
63+
rejected or may be published as general disclosures.
64+
{% else %}
65+
rejected.
66+
{% endif %}
67+
</p>
68+
69+
<p>
70+
If you have any questions or problems with form then please contact
71+
<a href="mailto:ietf-ipr@ietf.org">ietf-ipr@ietf.org</a>. We do not
72+
accept IPR disclosures by email.
6473
</p>
6574

6675

ietf/templates/ipr/disclosure.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ <h1>IPR disclosures</h1>
1212

1313
<ul>
1414
<li><a href="{% url "ietf.ipr.views.new" "specific" %}">File a disclosure about your IPR related to a specific IETF contribution</a></li>
15-
<li><a href="{% url "ietf.ipr.views.new" "generic" %}">File an IPR disclosure that is not related to a specific IETF contribution</a></li>
15+
<li><a href="{% url "ietf.ipr.views.new" "general" %}">File an IPR disclosure that is not related to a specific IETF contribution</a></li>
1616
<li><a href="{% url "ietf.ipr.views.new" "third-party" %}">Notify the IETF of IPR other than your own</a></li>
1717
<li>To update an existing IPR disclosure, find the original disclosure and select "update this IPR disclosure".</li>
1818
<li><a href="{% url "ietf.ipr.views.search" %}">Search the IPR disclosures</a></li>

ietf/templates/ipr/list.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ <h1>Intellectual property rights disclosures</h1>
3333
{% endif %}
3434
</p>
3535

36-
<h2 class="anchor-target" id="generic">Generic IPR disclosures</h2>
36+
<h2 class="anchor-target" id="generic">General IPR disclosures</h2>
3737

3838
{% include "ipr/ipr_table.html" with iprs=generic_disclosures %}
3939

@@ -49,7 +49,7 @@ <h2 class="anchor-target" id="notify">Specific third-party IPR disclosures</h2>
4949

5050
<div class="col-md-2 hidden-print bs-docs-sidebar" id="affix">
5151
<ul class="nav nav-pills nav-stacked small" data-spy="affix">
52-
<li><a href="#generic">Generic IPR disclosures</a></li>
52+
<li><a href="#generic">General IPR disclosures</a></li>
5353
<li><a href="#specific">Specific IPR disclosures</a></li>
5454
<li><a href="#notify">Specific third-party IPR disclosures</a></li>
5555
</ul>

0 commit comments

Comments
 (0)