Attribute definition consists of a type keyword and zero or more metadata separated by single spaces. Each metadata consists of a name and value separated by the equals sign.
Metadata names start with lowercase letters and may contain lowercase letters and hyphens.
Metadata values can be one of the following:
- integer
-
optional minus sign followed by one or more decimal digits
- string
-
a sequence of characters enclosed in double qoutes, with double quote and backslash characters escaped as
\"
and\\
respectively - array of strings
-
zero or more strings separated by commas and enclosed in curly braces
The following metadata are supported by all attribute types:
- default (string)
-
initial value of the attribute for new issues (default: '')
- required (int)
-
if 1, the value of the attribute cannot be empty and the initial value must be specified (default: 0)
Keyword: TEXT
Value: any sequence of characters.
- max-length (int)
-
maximum number of characters (default: 80)
Keyword: ENUM
Value: one of the predefined values.
- items (array of strings)
-
list of allowed values of the attribute (required)
- editable (int)
-
if 1, any other value is also accepted (default: 0)
Keyword: NUMERIC
Value: a number with optional fixed-point fraction. Leading zeros are removed. Trailing zeros are added if necessary.
- min-value (string)
-
minimum allowed numeric value
- max-value (string)
-
maximum allowed numeric value
- decimal (int)
-
number of digits after the decimal point (default: 0)
Keyword: DATETIME
Value: date with optional time. Date format is yyyy-mm-dd
, time format is hh:mm
.
- time (int)
-
if 1, time is also required (default: 0)
Copyright © 2007-2009 WebIssues Team