Mercurial > farol
changeset 38:debdea976b8a
Add Descriptions for the edit_note fields
author | Benoît Allard <benoit.allard@greenbone.net> |
---|---|
date | Mon, 06 Oct 2014 15:13:04 +0200 |
parents | 0c726d873c7a |
children | a21f63c516ec |
files | farol/templates/document/edit_note.j2 |
diffstat | 1 files changed, 26 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/farol/templates/document/edit_note.j2 Mon Oct 06 14:53:38 2014 +0200 +++ b/farol/templates/document/edit_note.j2 Mon Oct 06 15:13:04 2014 +0200 @@ -30,13 +30,33 @@ {% block content %} <form role="form" method="POST"> -{{ selectinput("type", "Type", types, note and note._type or '') }} -{{ textinput("ordinal", "Ordinal", "", ordinal or note._ordinal, type="number", extras={'min': '1'}) }} -{{ textinput("title", "Title", "", note and note._title or '') }} -{{ textinput("audience", "Audience", "", note and note._audience or '') }} -{{ textarea("note", "Note", "", note and note._note or '', 10, required=True) }} +{% call selectinput("type", "Type", types, note and note._type or '') %} +<p><em>Type</em> can be one of the following:</p> +<ul> + <li><strong>General</strong>: A general, high-level note (<em>Title</em> may have more information).</li> + <li><strong>Details</strong>: A low-level detailed discussion (<em>Title</em> may have more information).</li> + <li><strong>Description</strong>: A description of something (<em>Title</em> may have more information).</li> + <li><strong>Summary</strong>: A summary of something (<em>Title</em> may have more information).</li> + <li><strong>FAQ</strong>: A list of frequently asked questions.</li> + <li><strong>Legal Disclaimer</strong>: Any possible legal discussion, including constraints, surrounding the document.</li> + <li><strong>Other</strong>: Something that doesn’t fit (<em>Title</em> should have more information).</li> +{% endcall %} +{% call textinput("ordinal", "Ordinal", "", ordinal or note._ordinal, type="number", required=True, extras={'min': '1'}) %} +<p><em>Ordinal</em> is a mandatory, locally significant value used to track notes inside a CVRF document at the root (document) level. It is provided to uniquely identify a <strong>Note</strong>.</p> +<p>There should be one of these values for every <strong>Note</strong> inside <strong>Document Notes</strong>, and it is recommended that <em>Ordinal</em> should be instantiated as a monotonically increasing counter, indexed from 1. Each <em>Ordinal</em> that tracks a <strong>Note</strong> inside <strong>Document Notes</strong> is completely independent from an <em>Ordinal</em> tracking a <strong>Note</strong> inside <strong>Vulnerability/Notes</strong>.</p> +{% endcall %} +{% call textinput("title", "Title", "", note and note._title or '') %} +<p><em>Title</em> should be a concise description of what is contained in the text.</p> +{% endcall %} +{% call textinput("audience", "Audience", "", note and note._audience or '') %} +<p><em>Audience</em> will indicate who is intended to read it.</p> +{% endcall %} +{% call textarea("note", "Note", "", note and note._note or '', 10, required=True) %} +<p><strong>Note</strong> is a place to put all manner of text blobs related to the document as a whole. It can be a concise summary of the overall document or a more compartmentalized and area-specific textual discussion.</p> +<p>The note should contain a compartmentalized textual discussion constrained by its <em>Type</em> attribute.</p> +{% endcall %} <button class="btn btn-primary" type="submit">{{ action or 'Update' }}</button> -<a class="btn btn-danger" href="{% if action=='Add' %}{{ url_for('.view') }}{% else %}{{ url_for('view_note', ordinal=note._ordinal) }}{% endif %}">Cancel</a> +<a class="btn btn-danger" href="{% if action=='Add' %}{{ url_for('.view') }}{% else %}{{ url_for('.view_note', ordinal=note._ordinal) }}{% endif %}">Cancel</a> </form> {% endblock %}