RedmineCustomFields » History » Version 28
Ivan Garcia, 2018-04-19 16:32
1 | 13 | Jim Kovacs | h1. Custom fields |
---|---|---|---|
2 | 1 | Jean-Philippe Lang | |
3 | 4 | Mischa The Evil | {{>toc}} |
4 | 1 | Jean-Philippe Lang | |
5 | 4 | Mischa The Evil | Custom fields allow you to add additional information to several types of data used in Redmine. See '[[RedmineCustomFields#Custom-field-types|custom field types]]' for all types of data which come with support for custom fields. |
6 | Each custom field can be defined to be of a [[RedmineCustomFields#Custom-field-supporting-data-types|certain type]]. |
||
7 | |||
8 | h2. Custom field types |
||
9 | |||
10 | 24 | Go MAEDA | h3. Format |
11 | |||
12 | A custom field can be of one the following types: |
||
13 | 1 | Jean-Philippe Lang | * *Boolean*: checkbox |
14 | 21 | @ go2null | * *Date*: date |
15 | * *Float*: floating point number |
||
16 | * *Integer*: positive or negative number |
||
17 | * *Link*: URL |
||
18 | 1 | Jean-Philippe Lang | * *List*: drop down list |
19 | 21 | @ go2null | * *Long Text*: resizeable multiple lines of text (supports rich text formatting as of 2.50) |
20 | * *Text*: multiple lines text (supports rich text formatting as of 2.50) |
||
21 | 1 | Jean-Philippe Lang | * *User* custom field format that can be used to reference a project member |
22 | * *Version* custom field format that can be used to reference version |
||
23 | |||
24 | 24 | Go MAEDA | h3. Validation |
25 | |||
26 | 1 | Jean-Philippe Lang | Some validations can be defined for each custom field: |
27 | * *Min - max length*: minimum and maximum length for the field (0 means that there is no restriction) |
||
28 | * *Regular Expression*: a regular expression can be used to validate the field content. Examples: |
||
29 | ## _4 capital letters followed by one or several digits_ |
||
30 | <pre>^\[A-Z]{4}\d+$</pre> |
||
31 | ## _characters only, no digits_ |
||
32 | <pre>^[^0-9]*$</pre> |
||
33 | 21 | @ go2null | * A full list of regular expressions can be found in the Ruby Users Guide. |
34 | 1 | Jean-Philippe Lang | |
35 | 24 | Go MAEDA | h3. Values |
36 | |||
37 | 21 | @ go2null | Some field support multiple values and default values. |
38 | 22 | Anonymous | * *Multiple values*: while enabled, more than one item may be selected. |
39 | 1 | Jean-Philippe Lang | * *Possible values*: possible values for the "List" fields. One line for each value. |
40 | 21 | @ go2null | * *Default value*: default value to apply if none selected. |
41 | 1 | Jean-Philippe Lang | |
42 | 24 | Go MAEDA | h3. Text formatting |
43 | |||
44 | 21 | @ go2null | Some fields support text formatting. |
45 | * *Text formatting*: whether to wikify the text. If enabled, then _locks_ the *Link values to URL* field. |
||
46 | 25 | Go MAEDA | |
47 | 28 | Ivan Garcia | h3. Lists and Key/Values list |
48 | |||
49 | You can create your own list of values which you want your users to add. A posteriori change in values of "List" type will not affect any existing records created in the past, while a change in values of "Key/value list" will also affect existing records created in the past. |
||
50 | |||
51 | |||
52 | 27 | Go MAEDA | h3. Link values to URL |
53 | 1 | Jean-Philippe Lang | |
54 | 27 | Go MAEDA | "Link values to URL" can be defined for boolean, date, list, integer and text format fields. |
55 | 25 | Go MAEDA | |
56 | 21 | @ go2null | * *Link values to URL*: creates a URL using the following variables. |
57 | ** @%value%@ => the custom field value |
||
58 | ** @%id%@ => id of the customized object |
||
59 | ** @%project_id%@ => id of the project of the customized object if defined |
||
60 | 1 | Jean-Philippe Lang | ** @%project_identifier%@ => identifier of the project of the customized object if defined |
61 | ** @%m1%, %m2%...@ => capture groups matches of the custom field regexp if defined |
||
62 | 26 | Go MAEDA | |
63 | Example: |
||
64 | <pre> |
||
65 | https://www.redmine.org/issues/%value% |
||
66 | </pre> |
||
67 | 1 | Jean-Philippe Lang | |
68 | 24 | Go MAEDA | h3. Input field styling |
69 | |||
70 | 22 | Anonymous | (2.5.2+) Some fields may be displayed as radio buttons or checkboxes, with slightly different behaviour based on the selected "Format": |
71 | * *Boolean*: checkbox (enabled/disabled) or radio buttons (null/yes/no) |
||
72 | * *List*, *User* and *Version*: |
||
73 | ** checkboxes (if *Multiple values* is enabled) |
||
74 | 21 | @ go2null | ** radio buttons (if *Multiple values* is disabled) |
75 | 1 | Jean-Philippe Lang | |
76 | h2. Custom field supporting data types |
||
77 | |||
78 | 4 | Mischa The Evil | h3. Fields for Issues |
79 | |||
80 | 10 | Mischa The Evil | Data in issue custom fields can be used and/or will be displayed in [[RedmineIssues|issues]], [[RedmineIssueList|issue lists]], [[RedmineIssueList#Custom-queries|custom queries]] and the [[RedmineTimelogReport|Timelog report]]. |
81 | 5 | Mischa The Evil | |
82 | 11 | Mischa The Evil | * *Trackers*: TODO |
83 | 4 | Mischa The Evil | * *Required*: field which is required in order to create/save an issue |
84 | * *For all projects*: if checked, this field is used for the issues of all the projects. If unchecked, each project can choose whether or not to use the field for its issues (see [[RedmineProjectSettings|Project settings]]). |
||
85 | 11 | Mischa The Evil | * *Used as a filter*: TODO |
86 | 5 | Mischa The Evil | * *Searchable*: field which is searchable using the Redmine [[RedmineSearch|search function]] |
87 | 1 | Jean-Philippe Lang | |
88 | 4 | Mischa The Evil | h3. Fields for Spent time entries |
89 | 1 | Jean-Philippe Lang | |
90 | 10 | Mischa The Evil | Data in spent time entry custom fields can be used and/or will be displayed in the [[RedmineTimelogReport|Timelog report]]. |
91 | 5 | Mischa The Evil | |
92 | 4 | Mischa The Evil | * *Required*: field which is required in order to create/save a spent time entry |
93 | 1 | Jean-Philippe Lang | |
94 | 4 | Mischa The Evil | h3. Fields for Projects |
95 | 1 | Jean-Philippe Lang | |
96 | 10 | Mischa The Evil | Data in project custom fields can be used and/or will be displayed in the [[RedmineProjectOverview|Project overview]]. |
97 | 5 | Mischa The Evil | |
98 | 1 | Jean-Philippe Lang | * *Required*: field which is required in order to create/save a project |
99 | 5 | Mischa The Evil | * *Searchable*: field which is searchable using the Redmine [[RedmineSearch|search function]] |
100 | 1 | Jean-Philippe Lang | |
101 | 4 | Mischa The Evil | h3. Fields for Versions |
102 | 1 | Jean-Philippe Lang | |
103 | 10 | Mischa The Evil | Data in version custom fields can be used and/or will be displayed in the [[RedmineRoadmap|Roadmap]] and the [[RedmineVersion|Version overview]]. |
104 | 6 | Mischa The Evil | |
105 | 4 | Mischa The Evil | * *Required*: field which is required in order to create/save a version |
106 | |||
107 | h3. Fields for Users |
||
108 | |||
109 | 10 | Mischa The Evil | Data in user custom fields can be used and/or will be displayed in the [[RedmineUserProfiles|user profiles]]. |
110 | 6 | Mischa The Evil | |
111 | 1 | Jean-Philippe Lang | * *Required*: field which is required in order to create/save a user |
112 | 19 | Etienne Massip | * *Visible*: field which is displayed in the [[RedmineUserProfiles|user profile]] |
113 | 6 | Mischa The Evil | * *Editable*: field which is editable by the [[RedmineAccounts|Redmine user]] owning the user account |
114 | 4 | Mischa The Evil | |
115 | h3. Fields for Groups |
||
116 | 1 | Jean-Philippe Lang | |
117 | 9 | Mischa The Evil | *Note*: group custom fields are not (yet) used in the Redmine core, though other plugins or themes _can/may_ use them. No setting here has any effect on any other parts of Redmine for the time being. |
118 | 4 | Mischa The Evil | |
119 | 1 | Jean-Philippe Lang | h3. Fields for Activities (time tracking) |
120 | |||
121 | 23 | Mischa The Evil | Data in time tracking activity custom fields can be used and/or will be displayed[1] in the [[RedmineTimelogReport|Timelog report]] and the [[RedmineProjectSettings#Activities-time-tracking|Project settings]]. See also #4077 for some details about this nifty feature. |
122 | 7 | Mischa The Evil | |
123 | 4 | Mischa The Evil | * *Required*: field which is required in order to create/save an activity |
124 | 1 | Jean-Philippe Lang | |
125 | h3. Fields for Issue priorities |
||
126 | 4 | Mischa The Evil | |
127 | 9 | Mischa The Evil | *Note*: issue priority custom fields are not (yet) used in the Redmine core, though other plugins or themes _can/may_ use them. No setting here has any effect on any other parts of Redmine for the time being. |
128 | 8 | Felix Schäfer | |
129 | 7 | Mischa The Evil | h3. Fields for Document categories |
130 | 4 | Mischa The Evil | |
131 | 1 | Jean-Philippe Lang | *Note*: document category custom fields are not (yet) used in the Redmine core, though other plugins or themes _can/may_ use them. No setting here has any effect on any other parts of Redmine for the time being. |
132 | 23 | Mischa The Evil | |
133 | fn1. there are some exceptions, see #19121#note-1. |