Changed the IPR disclosure page for IPR disclosure updates to show both the previous and current disclosure details side-by-side. Fixes issue #2414.

- Legacy-Id: 14581
This commit is contained in:
Henrik Levkowetz 2018-01-27 21:34:52 +00:00
parent 717868cae2
commit 46472401ad
3 changed files with 221 additions and 86 deletions

View file

@ -769,12 +769,17 @@ def show(request, id):
elif ipr.state.slug != 'posted': elif ipr.state.slug != 'posted':
raise Http404 raise Http404
updates_iprs = ipr.relatedipr_source_set.all().order_by('source__time')
prev_rel = updates_iprs.last()
prev = prev_rel.target.get_child() if prev_rel else None
return render(request, "ipr/details_view.html", { return render(request, "ipr/details_view.html", {
'ipr': ipr, 'ipr': ipr,
'prev': prev,
'in_force_ipr_rfc': ipr_rfc_number(ipr.time, ipr.is_thirdparty), 'in_force_ipr_rfc': ipr_rfc_number(ipr.time, ipr.is_thirdparty),
'tabs': get_details_tabs(ipr, 'Disclosure'), 'tabs': get_details_tabs(ipr, 'Disclosure'),
'choices_abc': [ i.desc for i in IprLicenseTypeName.objects.filter(slug__in=['no-license', 'royalty-free', 'reasonable', ]) ], 'choices_abc': [ i.desc for i in IprLicenseTypeName.objects.filter(slug__in=['no-license', 'royalty-free', 'reasonable', ]) ],
'updates_iprs': ipr.relatedipr_source_set.all().order_by('source__time'), 'updates_iprs': updates_iprs,
'updated_by_iprs': ipr.relatedipr_target_set.filter(source__state="posted").order_by('target__time') 'updated_by_iprs': ipr.relatedipr_target_set.filter(source__state="posted").order_by('target__time')
}) })

View file

@ -753,6 +753,23 @@ blockquote {
} }
.table-condensed th.ipr-label {
overflow: hidden;
clear: left;
text-align: right;
text-overflow: ellipsis;
padding-right: 1em;
vertical-align: top;
}
.table-condensed .ipr-prev {
color: #777;
background-color: #f0f0f0;
vertical-align: top;
}
.table-condensed .ipr-this {
vertical-align: top;
}
.rfcmarkup div { .rfcmarkup div {
margin-top: 1em; margin-top: 1em;
} }

View file

@ -73,20 +73,27 @@
of the original IPR disclosure.</p> of the original IPR disclosure.</p>
{% endif %} {% endif %}
{% if updated_by_iprs %} {% if updates_iprs or updated_by_iprs%}
<h2>Updated by</h2>
{% for item in updated_by_iprs %}
<p>
This IPR disclosure has been updated by IPR disclosure ID #{{ item.source.id }},
"<a href="{% url "ietf.ipr.views.show" id=item.source.id %}">{{ item.source.title }}</a>".
</p>
{% endfor %}
{% endif %}
{% if updates_iprs %}
<h2>Updates</h2> <h2>Updates</h2>
{% if updated_by_iprs %}
<dl class="dl-horizontal">
<dt>Updated by</dt>
<dd>
{% for item in updated_by_iprs %}
<div>
IPR Disclosure ID #{{ item.source.id }},
{% if item.source.state.slug == "removed" %}
"{{ item.source.title }}" (which was removed at the request of the submitter)
{% else %}
"<a href="{% url "ietf.ipr.views.show" id=item.source.id %}">{{ item.source.title }}</a>"
{% endif %}
</div>
{% endfor %}
</dl>
{% endif %}
{% if updates_iprs %}
<dl class="dl-horizontal"> <dl class="dl-horizontal">
<dt>Updates</dt> <dt>Updates</dt>
<dd> <dd>
@ -101,6 +108,7 @@
</div> </div>
{% endfor %} {% endfor %}
</dl> </dl>
{% endif %}
{% endif %} {% endif %}
{% if user|has_role:"Secretariat" and ipr.update_notified_date %} {% if user|has_role:"Secretariat" and ipr.update_notified_date %}
@ -113,65 +121,128 @@
{% if ipr|to_class_name == "ThirdPartyIprDisclosure" %}Possible{% endif %} {% if ipr|to_class_name == "ThirdPartyIprDisclosure" %}Possible{% endif %}
Patent Holder/Applicant ("Patent Holder")</h2> Patent Holder/Applicant ("Patent Holder")</h2>
<dl class="dl-horizontal"> <table class="table-condensed col-md-12">
<dt>Holder legal name</dt> {% if prev %}
<dd>{{ ipr.holder_legal_name }}</dd> <tr><th class="ipr-prev">Previous (<a href="{% url "ietf.ipr.views.show" id=prev.id %}">#{{prev.id}}</a>)</th><th></th><th>This (#{{ipr.id}})</th></tr>
</dl> {% endif %}
<tr>
{% if prev %}<td class="col-md-5 ipr-prev">{{ prev.holder_legal_name }}</td>{% endif %}
<th class="col-md-2 ipr-label">Holder legal name</th>
<td class="col-md-5 ipr-this">{{ ipr.holder_legal_name }}</td>
</tr>
</table>
{% if ipr.holder_contact_name or ipr.holder_contact_info %} {% if ipr.holder_contact_name or ipr.holder_contact_info %}
<h2>{% cycle section %}. Patent Holder's Contact for License Application</h2> <h2>{% cycle section %}. Patent Holder's Contact for Licence Application</h2>
<dl class="dl-horizontal"> <table class="table-condensed col-md-12">
<dt>Holder contact name</dt> {% if prev %}
<dd>{{ ipr.holder_contact_name }}</dd> <tr><th class="ipr-prev">Previous (<a href="{% url "ietf.ipr.views.show" id=prev.id %}">#{{prev.id}}</a>)</th><th></th><th>This (#{{ipr.id}})</th></tr>
{% endif %}
<dt>Holder contact email</dt> <tr>
<dd>{{ ipr.holder_contact_email }}</dd> {% if prev %}<td class="col-md-5 ipr-prev">{{ prev.holder_contact_name }}</td>{% endif %}
<th class="col-md-2 ipr-label">Holder contact name</th>
<td class="col-md-5 ipr-this">{{ ipr.holder_contact_name }}</td>
</tr>
<dt>Holder contact info</dt> <tr>
<dd>{{ ipr.holder_contact_info|linebreaks }}</dd> {% if prev %}<td class="col-md-5 ipr-prev">{{ prev.holder_contact_email }}</td>{% endif %}
</dl> <th class="col-md-2 ipr-label">Holder contact email</th>
{% endif %} <td class="col-md-5 ipr-this">{{ ipr.holder_contact_email }}</td>
</tr>
<tr>
{% if prev %}<td class="col-md-5 ipr-prev">{{ prev.holder_contact_info|linebreaks }}</td>{% endif %}
<th class="col-md-2 ipr-label">Holder contact info</th>
<td class="col-md-5 ipr-this">{{ ipr.holder_contact_info|linebreaks }}</td>
</tr>
</table>
{% endif %}
{% if ipr.ietfer_name or ipr.ietfer_contact_email or ipr.ietfer_contact_info %} {% if ipr.ietfer_name or ipr.ietfer_contact_email or ipr.ietfer_contact_info %}
<h2>{% cycle section %}. Contact Information for the IETF Participant Whose Personal Belief Triggered this Disclosure</h2> <h2>{% cycle section %}. Contact Information for the IETF Participant Whose Personal Belief Triggered this Disclosure</h2>
<dl class="dl-horizontal"> <table class="table-condensed col-md-12">
<dt>Name</dt> {% if prev %}
<dd>{{ ipr.ietfer_name }}</dd> <tr><th class="ipr-prev">Previous (<a href="{% url "ietf.ipr.views.show" id=prev.id %}">#{{prev.id}}</a>)</th><th></th><th>This (#{{ipr.id}})</th></tr>
{% endif %}
<tr>
{% if prev %}<td class="col-md-5 ipr-prev">{{ prev.ietfer_name }}</td>{% endif %}
<th class="col-md-2 ipr-label">Name</th>
<td class="col-md-5 ipr-this">{{ ipr.ietfer_name }}</td>
</tr>
<dt>Email</dt> <tr>
<dd>{{ ipr.ietfer_contact_email }}</dd> {% if prev %}<td class="col-md-5 ipr-prev">{{ prev.ietfer_contact_email }}</td>{% endif %}
<th class="col-md-2 ipr-label">Email</th>
<td class="col-md-5 ipr-this">{{ ipr.ietfer_contact_email }}</td>
</tr>
<dt>Other info</dt> <tr>
<dd>{{ ipr.ietfer_contact_info|linebreaks }}</dd> {% if prev %}<td class="col-md-5 ipr-prev">{{ prev.ietfer_contact_info|linebreaks }}</td>{% endif %}
</dl> <th class="col-md-2 ipr-label">Other info</th>
<td class="col-md-5 ipr-this">{{ ipr.ietfer_contact_info|linebreaks }}</td>
</tr>
</table>
{% endif %} {% endif %}
{% if ipr.iprdocrel_set.all or ipr.other_designations %} {% if ipr.iprdocrel_set.all or ipr.other_designations %}
<h2>{% cycle section %}. IETF Document or Other Contribution to Which this IPR Disclosure Relates</h2> <h2>{% cycle section %}. IETF Document or Other Contribution to Which this IPR Disclosure Relates</h2>
<dl class="dl-horizontal"> <table class="table-condensed col-md-12">
{% for iprdocrel in ipr.iprdocrel_set.all %} {% if prev %}
<dt>{{ iprdocrel.doc_type }}</dt> <tr><th class="ipr-prev">Previous (<a href="{% url "ietf.ipr.views.show" id=prev.id %}">#{{prev.id}}</a>)</th><th></th><th>This (#{{ipr.id}})</th></tr>
<dd> {% endif %}
<div>{{ iprdocrel.formatted_name }} ("{{ iprdocrel.document.document.title }}")</div> <tr>
{% if iprdocrel.revisions %} {% if prev %}
<div>Revisions: {{ iprdocrel.revisions }}</div> <td class="col-md-5 ipr-prev">
{% endif %} {% for iprdocrel in prev.iprdocrel_set.all %}
<b>{{ iprdocrel.doc_type }}:</b>
{{ iprdocrel.formatted_name }} ("{{ iprdocrel.document.document.title }}")
{% if iprdocrel.sections %} {% if iprdocrel.revisions %}
<div>Sections: {{ iprdocrel.sections }}</div> <div>Revisions: {{ iprdocrel.revisions }}</div>
{% endif %} {% endif %}
</dd>
{% endfor %}
{% if ipr.other_designations %} {% if iprdocrel.sections %}
<dt>Designations for Other Contributions</dt> <div>Sections: {{ iprdocrel.sections }}</div>
<dd>{{ ipr.other_designations }}</dd> {% endif %}
{% endif %} {% endfor %}
</dl>
{% if prev.other_designations %}
<b>Designations for Other Contributions</b>
{{ prev.other_designations }}
{% endif %}
</td>
{% endif %}
<th class="col-md-2 ipr-label"></th>
<td class="col-md-5 ipr-this">
{% for iprdocrel in ipr.iprdocrel_set.all %}
<b>{{ iprdocrel.doc_type }}:</b>
{{ iprdocrel.formatted_name }} ("{{ iprdocrel.document.document.title }}")
{% if iprdocrel.revisions %}
<div>Revisions: {{ iprdocrel.revisions }}</div>
{% endif %}
{% if iprdocrel.sections %}
<div>Sections: {{ iprdocrel.sections }}</div>
{% endif %}
{% endfor %}
{% if ipr.other_designations %}
<dt>Designations for Other Contributions</dt>
<dd>{{ ipr.other_designations }}</dd>
{% endif %}
</td>
<tr>
</table>
{% endif %} {% endif %}
{% if ipr.patent_info or ipr.has_patent_pending %} {% if ipr.patent_info or ipr.has_patent_pending %}
@ -179,17 +250,29 @@
<p>A. For granted patents or published pending patent applications, please provide the following information:</p> <p>A. For granted patents or published pending patent applications, please provide the following information:</p>
<dl class="dl-horizontal"> <table class="table-condensed col-md-12">
<dt>Patent, Serial, Publication, Registration, or Application/File number(s)</dt> {% if prev %}
<dd>{{ ipr.patent_info|linebreaks }}</dd> <tr><th class="ipr-prev">Previous (<a href="{% url "ietf.ipr.views.show" id=prev.id %}">#{{prev.id}}</a>)</th><th></th><th>This (#{{ipr.id}})</th></tr>
</dl> {% endif %}
<tr>
{% if prev %}<td class="col-md-5 ipr-prev">{{ prev.patent_info|linebreaks }}</td>{% endif %}
<th class="col-md-2 ipr-label">Patent, Serial, Publication, Registration, or Application/File number(s)</th>
<td class="col-md-5 ipr-this">{{ ipr.patent_info|linebreaks }}</td>
</tr>
</table>
<p>B. Does this disclosure relate to an unpublished pending patent application?:</p> <p>B. Does this disclosure relate to an unpublished pending patent application?:</p>
<dl class="dl-horizontal"> <table class="table-condensed col-md-12">
<dt>Has patent pending</dt> {% if prev %}
<dd>{{ ipr.has_patent_pending|yesno:"Yes,No" }}</dd> <tr><th class="ipr-prev">Previous (<a href="{% url "ietf.ipr.views.show" id=prev.id %}">#{{prev.id}}</a>)</th><th></th><th>This (#{{ipr.id}})</th></tr>
</dl> {% endif %}
<tr>
{% if prev %}<td class="col-md-5 ipr-prev">{{ prev.has_patent_pending|yesno:"Yes,No" }}</td>{% endif %}
<th class="col-md-2 ipr-label">Has patent pending</th>
<td class="col-md-5 ipr-this">{{ ipr.has_patent_pending|yesno:"Yes,No" }}</td>
</tr>
</table>
{% endif %} {% endif %}
{% if ipr.licensing %} {% if ipr.licensing %}
@ -204,23 +287,32 @@
specification, is as follows(select one licensing declaration option only): specification, is as follows(select one licensing declaration option only):
</p> </p>
{% if ipr.licensing.slug == "provided-later" %} {% if prev.licensing.slug == "provided-later" or ipr.licensing.slug == "provided-later" %}
<div> <div>
Possible licencing choices a), b), and c) when Licencing Declaration to be Provided Later: Possible licensing choices a), b), and c) when Licensing Declaration to be Provided Later:
<ul style="list-style: none"> <ul style="list-style: none">
{% for desc in choices_abc %} {% for desc in choices_abc %}
<li>{{ desc}}</li> <li>{{ desc}}</li>
{% endfor %} {% endfor %}
</ul> </ul>
</p> </div>
{% endif %} {% endif %}
<dl class="dl-horizontal">
<dt>Licensing</dt>
<dd>{% if ipr.licensing.slug == "provided-later" %}{{ ipr.licensing.desc|slice:"2:"|slice:":117" }}){% else %}{{ ipr.licensing.desc|slice:"2:" }}{% endif %}</dd>
<dt>Licensing information, comments, notes, or URL for further information</dt> <table class="table-condensed col-md-12">
<dd>{{ ipr.licensing_comments|default:"(No information submitted)"|linebreaks }}</dd> {% if prev %}
</dl> <tr><th class="ipr-prev">Previous (<a href="{% url "ietf.ipr.views.show" id=prev.id %}">#{{prev.id}}</a>)</th><th></th><th>This (#{{ipr.id}})</th></tr>
{% endif %}
<tr>
{% if prev %}<td class="col-md-5 ipr-prev">{% if prev.licensing.slug == "provided-later" %}{{ prev.licensing.desc|slice:"2:"|slice:":117" }}){% else %}{{ prev.licensing.desc|slice:"2:" }}{% endif %}</td>{% endif %}
<th class="col-md-2 ipr-label">Licensing</th>
<td class="col-md-5 ipr-this">{% if ipr.licensing.slug == "provided-later" %}{{ ipr.licensing.desc|slice:"2:"|slice:":117" }}){% else %}{{ ipr.licensing.desc|slice:"2:" }}{% endif %}</td>
</tr>
<tr>
{% if prev %}<td class="col-md-5 ipr-prev">{{ prev.licensing_comments|default:"(No information submitted)"|linebreaks }}</td>{% endif %}
<th class="col-md-2 ipr-label">Licensing information, comments, notes, or URL for further information</th>
<td class="col-md-5 ipr-this">{{ ipr.licensing_comments|default:"(No information submitted)"|linebreaks }}</td>
</tr>
</table>
<p>Note: The individual submitting this template represents and warrants <p>Note: The individual submitting this template represents and warrants
that he or she is authorized by the Patent Holder to agree to the that he or she is authorized by the Patent Holder to agree to the
@ -229,33 +321,54 @@
{% elif ipr.statement %} {% elif ipr.statement %}
<h2>{% cycle section %}. Statement</h2> <h2>{% cycle section %}. Statement</h2>
<dl class="dl-horizontal"> <table class="table-condensed col-md-12">
<dt>Statement</dt> {% if prev %}
<dd>{{ ipr.statement|linebreaks }}</dd> <tr><th class="ipr-prev">Previous (<a href="{% url "ietf.ipr.views.show" id=prev.id %}">#{{prev.id}}</a>)</th><th></th><th>This (#{{ipr.id}})</th></tr>
</dl> {% endif %}
<tr>
{% if prev %}<td class="col-md-5 ipr-prev">{{ prev.statement|linebreaks }}</td>{% endif %}
<th class="col-md-2 ipr-label">Statement</th>
<td class="col-md-5 ipr-this">{{ ipr.statement|linebreaks }}</td>
</tr>
</table>
{% endif %} {% endif %}
<h2>{% cycle section %}. Contact Information of Submitter of this Form</h2> <h2>{% cycle section %}. Contact Information of Submitter of this Form</h2>
<dl class="dl-horizontal"> <table class="table-condensed col-md-12">
<dt>Submitter name</dt> {% if prev %}
<dd>{{ ipr.submitter_name }}</dd> <tr><th class="ipr-prev">Previous (<a href="{% url "ietf.ipr.views.show" id=prev.id %}">#{{prev.id}}</a>)</th><th></th><th>This (#{{ipr.id}})</th></tr>
{% endif %}
<tr>
{% if prev %}<td class="col-md-5 ipr-prev">{{ prev.submitter_name }}</td>{% endif %}
<th class="col-md-2 ipr-label">Submitter name</th>
<td class="col-md-5 ipr-this">{{ ipr.submitter_name }}</td>
</tr>
<dt>Submitter email</dt> <tr>
<dd>{{ ipr.submitter_email }}</dd> {% if prev %}<td class="col-md-5 ipr-prev">{{ prev.submitter_email }}</td>{% endif %}
</dl> <th class="col-md-2 ipr-label">Submitter email</th>
<td class="col-md-5 ipr-this">{{ ipr.submitter_email }}</td>
</tr>
</table>
{% if ipr.notes %} {% if ipr.notes %}
<h2>{% cycle section %}. Other Notes</h2> <h2>{% cycle section %}. Other Notes</h2>
<dl class="dl-horizontal"> <table class="table-condensed col-md-12">
<dt>Additional notes</dt> {% if prev %}
<dd>{{ ipr.notes|linebreaks }}</dd> <tr><th class="ipr-prev">Previous (<a href="{% url "ietf.ipr.views.show" id=prev.id %}">#{{prev.id}}</a>)</th><th></th><th>This (#{{ipr.id}})</th></tr>
</dl> {% endif %}
<tr>
{% if prev %}<td class="col-md-5 ipr-prev">{{ prev.notes|linebreaks }}</td>{% endif %}
<th class="col-md-2 ipr-label">Additional notes</th>
<td class="col-md-5 ipr-this">{{ ipr.notes|linebreaks }}</td>
</tr>
</table>
{% endif %} {% endif %}
</div> </div>
<p class="help-block">Only those sections of the relevant entry form where the submitter provided information are displayed.</p> <p class="help-block">Only those sections of the relevant entry form where the submitter provided information are displayed.</p>
</div> </div>
{% endblock content %} {% endblock content %}