Skip to content

Commit 65f15c7

Browse files
committed
Reverting to revision [151] -- committed way too much by mistake
- Legacy-Id: 153 Note: SVN reference [151] has been migrated to Git commit fca8b30
1 parent d981d5a commit 65f15c7

6 files changed

Lines changed: 45 additions & 66 deletions

File tree

ietf/ipr/models.py

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -79,11 +79,11 @@ class IprDetail(models.Model):
7979

8080
# Patent Information fieldset
8181
p_applications = models.TextField("Patent Applications", maxlength=255)
82-
date_applied = models.CharField(maxlength=255)
82+
date_applied = models.DateField(maxlength=255)
8383
country = models.CharField(maxlength=100)
8484
p_notes = models.TextField("Additional notes", blank=True)
85-
selecttype = models.IntegerField("Unpublished Pending Patent Application", choices=SELECT_CHOICES)
86-
selectowned = models.IntegerField("Applies to all IPR owned by Submitter", choices=SELECT_CHOICES)
85+
selecttype = models.IntegerField("Unpublished Pending Patent Application", null=True, choices=SELECT_CHOICES)
86+
selectowned = models.IntegerField("Applies to all IPR owned by Submitter", null=True, blank=True, choices=SELECT_CHOICES)
8787

8888
# Licensing Declaration fieldset
8989
#licensing_option = models.ForeignKey(IprLicensing, db_column='licensing_option')
@@ -94,18 +94,16 @@ class IprDetail(models.Model):
9494
comments = models.TextField("Licensing Comments", blank=True)
9595
lic_checkbox = models.BooleanField("All terms and conditions has been disclosed")
9696

97+
third_party = models.BooleanField(editable=False)
9798

9899
# Other notes fieldset
99100
other_notes = models.TextField(blank=True)
100101

101102
# Generated fields, not part of the submission form
102-
# Hidden fields
103-
third_party = models.BooleanField()
104-
generic = models.BooleanField()
105-
comply = models.BooleanField()
106-
107103
status = models.IntegerField(null=True, blank=True)
108-
submitted_date = models.DateField(blank=True)
104+
comply = models.BooleanField(editable=False)
105+
generic = models.BooleanField(editable=False)
106+
submitted_date = models.DateField(null=True, blank=True)
109107
update_notified_date = models.DateField(null=True, blank=True)
110108

111109
def __str__(self):

ietf/ipr/view_new.py

Lines changed: 3 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
from ietf.utils import log
88
from ietf.ipr.view_sections import section_table
99
from ietf.idtracker.models import Rfc, InternetDraft
10-
from django.http import HttpResponseRedirect
1110

1211
# ----------------------------------------------------------------
1312
# Callback methods for special field cases.
@@ -21,8 +20,6 @@ def ipr_detail_form_callback(field, **kwargs):
2120
if field.name in ["rfc_number", "id_document_tag"]:
2221
log(field.name)
2322
return forms.CharFieldField(required=False)
24-
if field.name in ["date_applied"]:
25-
return forms.DateField()
2623
return field.formfield(**kwargs)
2724

2825
def ipr_contact_form_callback(field, **kwargs):
@@ -157,15 +154,7 @@ def clean_draftlist(self):
157154
raise forms.ValidationError("Unknown Internet-Draft: %s - please correct this." % filename)
158155
if rev and id.revision != rev:
159156
raise forms.ValidationError("Unexpected revision '%s' for draft %s - the current revision is %s. Please check this." % (rev, filename, id.revision))
160-
def clean_document_title(self):
161-
log("clean_data: %s" % self.data)
162-
if type == "general":
163-
return """%(p_h_legal_name)s's license statement""" % self.data
164-
if type == "specific":
165-
return """%(p_h_legal_name)s's Statement about IPR related to ...""" % self.data
166-
if type == "third-party":
167-
return """%(submitter)s's Statement about IPR related to ... belonging to %(p_h_legal_name)s""" % self.data
168-
raise KeyError("Unexpected IPR disclosure type '%s'" % type)
157+
pass
169158

170159
if request.method == 'POST':
171160
data = request.POST.copy()
@@ -181,8 +170,8 @@ def clean_document_title(self):
181170
if form.ietf_contact_is_submitter:
182171
form.ietf_contact_is_submitter_checked = "checked"
183172
if form.is_valid():
184-
instance = form.save()
185-
return HttpResponseRedirect("/ipr/ipr-%s" % instance.ipr_id)
173+
#instance = form.save()
174+
#return HttpResponseRedirect("/ipr/ipr-%s" % instance.ipr_id)
186175
#return HttpResponseRedirect("/ipr/")
187176

188177
pass

ietf/ipr/view_sections.py

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,23 @@
11

22
section_table = {
33
"index": { "index": True },
4-
"specific": { "index": False, "title": True,
5-
"specific": 1, "generic": 0, "third_party": 0,
4+
"specific": { "index": False, "title": True, "specific": True,
65
"legacy_intro": False, "new_intro": True, "form_intro": False,
76
"holder": True, "holder_contact": True, "ietf_contact": True,
87
"ietf_doc": True, "patent_info": True, "licensing": True,
98
"submitter": True, "notes": True, "form_submit": False,
109
"disclosure_type": "Specific", "form_legend": False,
1110
"per_rfc_disclosure": True, "also_specific": False,
1211
},
13-
"generic": { "index": False, "title": True,
14-
"specific": 0, "generic": 1, "third_party": 0,
12+
"generic": { "index": False, "title": True, "generic": True,
1513
"legacy_intro": False, "new_intro": True, "form_intro": False,
1614
"holder": True, "holder_contact": True, "ietf_contact": False,
1715
"ietf_doc": False, "patent_info": True, "licensing": True,
1816
"submitter": True, "notes": True, "form_submit": False,
1917
"disclosure_type": "Generic", "form_legend": False,
2018
"per_rfc_disclosure": False, "also_specific": True,
2119
},
22-
"third-party": {"index": False, "title": True,
23-
"specific": 0, "generic": 0, "third_party": 1,
20+
"third-party": {"index": False, "title": True, "third_party": True,
2421
"legacy_intro": False, "new_intro": True, "form_intro": False,
2522
"holder": True, "holder_contact": False, "ietf_contact": True,
2623
"ietf_doc": True, "patent_info": True, "licensing": False,

ietf/ipr/views.py

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
from django.utils.html import escape
66
from ietf.ipr.view_new import new
77
from ietf.ipr.view_sections import section_table
8-
from ietf.utils import log
98

109
def linebreaks(value):
1110
if value:
@@ -63,10 +62,9 @@ def show(request, ipr_id=None):
6362
ipr.comments = linebreaks(escape(ipr.comments))
6463
ipr.other_notes = linebreaks(escape(ipr.other_notes))
6564

66-
if ipr.licensing_option:
67-
ipr.licensing_option = dict(models.LICENSE_CHOICES)[ipr.licensing_option]
68-
if ipr.selecttype:
69-
ipr.selecttype = dict(models.SELECT_CHOICES)[ipr.selecttype]
65+
ipr.licensing_option = dict(models.LICENSE_CHOICES)[ipr.licensing_option]
66+
ipr.selecttype = dict(models.SELECT_CHOICES)[ipr.selecttype]
67+
7068
if ipr.selectowned:
7169
ipr.selectowned = dict(models.SELECT_CHOICES)[ipr.selectowned]
7270
return render("ipr/details.html", {"ipr": ipr, "section_list": section_list})
@@ -84,9 +82,9 @@ def get_section_list(ipr):
8482
if ipr.old_ipr_url:
8583
return section_table["legacy"]
8684
elif ipr.generic:
87-
#assert not ipr.third_party
85+
assert not ipr.third_party
8886
return section_table["generic"]
8987
elif ipr.third_party:
90-
return section_table["third-party"]
88+
return section_table["third_party"]
9189
else:
9290
return section_table["specific"]

ietf/templates/ipr/details.html

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -475,9 +475,6 @@ <h4 class="ipr">The Patent Disclosure and Licensing Declaration Template for {{
475475
{% endif %}
476476

477477
{% if section_list.form_submit %}
478-
<input type="hidden" name="third_party" value="{{ section_list.third_party }}">
479-
<input type="hidden" name="generic" value="{{ section_list.generic }}">
480-
<input type="hidden" name="comply" value="1">
481478
<center><input type="submit" name="submit" value="Submit"></center>
482479
</form>
483480
<blockquote>

ietf/templates/meeting/agenda.html

Lines changed: 27 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -22,32 +22,32 @@
2222
<br>
2323
{% regroup object_list by day_id as days %}
2424
{% for day in days %}
25-
<b>Day: {{ day.list.1.meeting_date|date:"l, F j, Y" }} </b><br>
26-
{{ day.list.1.reg_info }} - {{ meetingvenue_info.reg_area_name }} <br>
27-
{{ day.list.1.morning_br_info }} - {{ meetingvenue_info.break_area_name }} <br>
28-
<br>
29-
{% for item in day.list %}
30-
{% ifequal item.session_name_id 3 %}
31-
{{ day.list.1.lunch_br_info }} Break<br>
32-
{% endifequal %}
33-
{% ifequal item.session_name_id 4 %}
34-
{{ day.list.1.an_br1_info }}<br>
35-
{% endifequal %}
36-
{% ifequal item.session_name_id 5 %}
37-
{{ day.list.1.an_br2_info }}<br>
38-
{% endifequal %}
39-
<b>{{ item.time_desc }} {{ item.session_name }} </b><br>
40-
<table border="0" cellspacing="0" cellpadding="0" width="800">
41-
{% for session in item.sessions|dictsort:"area" %}
42-
{% ifequal session.acronym "plenaryw" %}
43-
<tr><td>{{ op_ad_plenary_agenda|linebreaksbr }}</td></tr>
44-
{% else %}
45-
<tr><td width="200">{{ session.sched_room_id1.room_name }}</td><td width="50">{{ session.area|upper }}</td><td width="100">{{ session.acronym }}</td><td>{{ session.acronym_name }}</td></tr>
46-
{% endifequal %}
47-
{% endfor %}
48-
</table>
49-
<br>
50-
{% endfor %}
51-
<br>
25+
<b>Day: {{ day.list.1.meeting_date|date:"l, F j, Y" }} </b><br>
26+
{{ day.list.1.reg_info }} - {{ meetingvenue_info.reg_area_name }} <br>
27+
{{ day.list.1.morning_br_info }} - {{ meetingvenue_info.break_area_name }} <br>
28+
<br>
29+
{% for item in day.list %}
30+
{% ifequal item.session_name_id 3 %}
31+
{{ day.list.1.lunch_br_info }} Break<br>
32+
{% endifequal %}
33+
{% ifequal item.session_name_id 4 %}
34+
{{ day.list.1.an_br1_info }}<br>
35+
{% endifequal %}
36+
{% ifequal item.session_name_id 5 %}
37+
{{ day.list.1.an_br2_info }}<br>
38+
{% endifequal %}
39+
<b>{{ item.time_desc }} {{ item.session_name }} </b><br>
40+
<table border="0" cellspacing="0" cellpadding="0" width="800">
41+
{% for session in item.sessions|dictsort:"area" %}
42+
{% ifequal session.acronym "plenaryw" %}
43+
<tr><td>{{ op_ad_plenary_agenda|linebreaksbr }}</td></tr>
44+
{% else %}
45+
<tr><td width="200">{{ session.sched_room_id1.room_name }}</td><td width="50">{{ session.area|upper }}</td><td width="100">{{ session.acronym }}</td><td>{{ session.acronym_name }}</td></tr>
46+
{% endifequal %}
47+
{% endfor %}
48+
</table>
49+
<br>
50+
{% endfor %}
51+
<br>
5252
{% endfor %}
5353
{% endblock %}

0 commit comments

Comments
 (0)