comparison farol/templates/document/edit_revision.j2 @ 126:e0830bcab004

Add (optional) regex matching to our input fields
author Benoît Allard <benoit.allard@greenbone.net>
date Thu, 23 Oct 2014 16:32:33 +0200
parents c79082d0d44d
children a7ce1660aaaf
comparison
equal deleted inserted replaced
125:67c4b299736e 126:e0830bcab004
28 {% block title %}Edit Revision{% endblock %} 28 {% block title %}Edit Revision{% endblock %}
29 29
30 {% block content %} 30 {% block content %}
31 <p><strong>Revision</strong> contains all the elements required to track the evolution of a CVRF document. Each change to a CVRF document should be accompanied by <strong>Number</strong>, <strong>Date</strong>, and <strong>Description</strong> elements.</p> 31 <p><strong>Revision</strong> contains all the elements required to track the evolution of a CVRF document. Each change to a CVRF document should be accompanied by <strong>Number</strong>, <strong>Date</strong>, and <strong>Description</strong> elements.</p>
32 <form role="form" method="POST"> 32 <form role="form" method="POST">
33 {% call textinput("number", "Number", "a.b.c.d", number, required=True) %} 33 {% call textinput("number", "Number", "a.b.c.d", number, required=True, regex='(0|[1-9][0-9]*)(\.(0|[1-9][0-9]*)){0,3}') %}
34 <p><strong>Number</strong> should contain the numeric version of the document. Like the <strong>Version</strong> element above, it is a numeric tokenized field of the format “nn” with up to four fields “nn.nn.nn.nn”. It is recommended that this be a monotonically increasing value. Minor revisions should be used for less-significant changes (for example, <samp>1.0.0.0</samp> to <samp>1.0.0.1</samp>). Major, actionable changes should lead to a major increase of the version number (for example, <samp>1.0</samp> to <samp>2.0</samp>).</p> 34 <p><strong>Number</strong> should contain the numeric version of the document. Like the <strong>Version</strong> element above, it is a numeric tokenized field of the format “nn” with up to four fields “nn.nn.nn.nn”. It is recommended that this be a monotonically increasing value. Minor revisions should be used for less-significant changes (for example, <samp>1.0.0.0</samp> to <samp>1.0.0.1</samp>). Major, actionable changes should lead to a major increase of the version number (for example, <samp>1.0</samp> to <samp>2.0</samp>).</p>
35 <p>Examples of such changes include:</p> 35 <p>Examples of such changes include:</p>
36 <ul> 36 <ul>
37 <li>Any change to severity or impact</li> 37 <li>Any change to severity or impact</li>
38 <li>The announcement of additional vulnerabilities</li> 38 <li>The announcement of additional vulnerabilities</li>

http://farol.wald.intevation.org