# HG changeset patch # User Benoît Allard # Date 1412683677 -7200 # Node ID 086e35c4aee70cec26b943727da13ae317d173d3 # Parent 7c4d001839e7b64fe266d9a896f1f5c727185797 Add description fields for edit_product and edit_branch diff -r 7c4d001839e7 -r 086e35c4aee7 farol/templates/producttree/edit_branch.j2 --- a/farol/templates/producttree/edit_branch.j2 Tue Oct 07 13:01:10 2014 +0200 +++ b/farol/templates/producttree/edit_branch.j2 Tue Oct 07 14:07:57 2014 +0200 @@ -30,8 +30,24 @@ {% block content %}
-{{ selectinput('type', "Type", types, branch._type) }} -{{ textinput('name', "Name", value=branch._name, required=True) }} +{% call selectinput('type', "Type", types, branch._type) %} +

Branch Types:

+
+
Vendor:
The name of the vendor or manufacturer that makes the product
+
Product Family:
The product family that the product falls into
+
Product Name:
The name of the product
+
Product Version:
The product version, can be numeric or some other descriptor
+
Patch Level:
The patch level of the product
+
Service Pack:
The service pack of the product
+
Architecture:
The architecture for which the product is intended
+
Language:
The language of the product
+
Legacy:
A nonspecific legacy entry
+
Specification:
A specification such as a standard, best common practice, etc.
+
+{% endcall %} +{% call textinput('name', "Name", value=branch._name, required=True) %} +

Name will contain the canonical descriptor or “friendly name” of the branch.

+{% endcall %} {{ selectinput2('parent', "Path to Parent Branch", branches, branch.getParentPath()) }} diff -r 7c4d001839e7 -r 086e35c4aee7 farol/templates/producttree/edit_product.j2 --- a/farol/templates/producttree/edit_product.j2 Tue Oct 07 13:01:10 2014 +0200 +++ b/farol/templates/producttree/edit_product.j2 Tue Oct 07 14:07:57 2014 +0200 @@ -24,17 +24,25 @@ -#} {% extends "base.j2" %} -{% from "macros.j2" import textinput, selectinput2 %} +{% from "macros.j2" import textinput, selectinput2, examples %} {% block title %}Edit the product{% endblock %} {% set active = 'product' %} {% block content %} - +

The Full Product Name elements define the endpoints of the Product Tree and occur directly at the root level, at the branch level, or as the result of a relationship between two products.

-{{ textinput('name', "Product Name", value=product._name, required=True) }} -{{ textinput('productid', "ProductID", placeholder="1234", value=product._productid, required=True) }} -{{ textinput('cpe', "CPE", placeholder="cpe:/a:...", value=product._cpe) }} +{% call textinput('name', "Product Name", value=product._name, required=True) %} +

The value of a Full Product Name element should be the product’s full canonical name, including version number and other attributes, as it would be used in a human-friendly document.

+{{ examples(['Microsoft Host Integration Server 2006 Service Pack 1', 'Microsoft Office 2008 for Mac 12.3.1 Update']) }} +{% endcall %} +{% call textinput('productid', "ProductID", placeholder="1234", value=product._productid, required=True) %} +

The Product ID attribute is required to identify a Full Product Name so that it can be referred to from other parts in the document. There is no predefined or required format for the Product ID as long as it uniquely identifies a product in the context of the current document. Examples include incremental integers or Globally Unique Identifiers (GUIDs).

+{{ examples(['CVRFPID-0004']) }} +{% endcall %} +{% call textinput('cpe', "CPE", placeholder="cpe:/a:...", value=product._cpe) %} +

The Common Platform Enumeration (CPE) attribute refers to a method for naming platforms. The structure for CPE is described at http://cpe.mitre.org. The CPE can be either an integer (if MITRE has an entry for the platform in question) or a candidate string from the vendor if no MITRE entry yet exists.

+{% endcall %}
{{ selectinput2('parent_branch', "Parent Branch", orphaned_leaves , product.getParentPath()) }} {{ selectinput2('parent_relationship', "Parent relationship", orphaned_relationships, current_rel) }}