Changes between Version 9 and Version 10 of MultiSelectFieldPlugin
- Timestamp:
- Nov 1, 2015, 12:05:06 PM (8 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
MultiSelectFieldPlugin
v9 v10 7 7 Plugin allowing custom fields in tickets supporting multiple selection mode. Predefined values must be defined for each field, from which multiple values can be selected by the user. 8 8 9 The data is saved as a normal text field with the values separated by '|'.9 The data is saved as a normal custom text field with the values separated by a single space (this way the normal trac ui will show the values in a sensible way too). Any spaces in the options is converted to '_' by default when saving the data. 10 10 11 11 The selection component itself is using http://harvesthq.github.io/chosen/ to implement multiple selection in a more user friendly way. … … 23 23 == Download 24 24 25 Download the zipped source from [download:multiselectfieldplugin here]. 26 27 == Source 28 29 You can check out MultiSelectFieldPlugin from [http://trac-hacks.org/svn/multiselectfieldplugin here] using Subversion, or [source:multiselectfieldplugin browse the source] with Trac. 25 Check out the [http://trac-hacks.org/svn/multiselectfieldplugin plugin] using Subversion or easy_install etc. 26 or [source:multiselectfieldplugin browse the source] with Trac. 27 or Download the [download:multiselectfieldplugin zipped source]. 30 28 31 29 == Example 32 30 33 Install and enable plugin. Then add a new custom field to your `conf/trac.ini`, for example: 31 Install and enable plugin. Then add a new custom field to your `conf/trac.ini`. 32 33 For example this will add a new field supporting multiple selection called 'environment' with some predefined values: 34 34 35 {{{ 35 36 #!ini … … 43 44 }}} 44 45 45 This will add a new field supporting multiple selection called 'environment' with some predefined values.46 47 46 [[Image(multiselectfield.2.png)]] 48 47 49 == TODO 48 NOTE: Adding new selection choices is always fine. However, be careful when changing the existing options of a field when there is existing data with the old options. When you view a ticket the ui will only show currently valid options. Any old options will be cleared when the ticket is modified and the field in question has been changed. 50 49 51 * Graphics are glitching a bit with the remove 'x' button. 52 * Behaviour when removing predefined option that is in use in existing tickets is not well defined or tested. 50 == Plugin config 51 52 The default config should be fine for most people, but if you need to change how the data is saved you can add these options under `[multiselectfield]` in `conf/trac.ini`: 53 54 `data_delimiter` (default value: ' ') 55 The delimiter that is used when storing the data (as the selected options are appended to a single custom text field). Space is used by default as values separated by space will be recognized by the custom text field in list mode as separate values. 56 57 `option_strip_whitespace` (default value: true) 58 Defined whether whitespace in the names of the predefined selectable values is removed before saving the data (whitespace will be converted to underscores). This should be enabled when using white space as data delimiter. 59 60 NOTE: changing options when there is already data saved with other options value is probably not a good idea. 53 61 54 62 == Recent Changes