Provide a syntax to assign custom fields for non-technical users
codescape opened this issue · comments
The current syntax is too complex for non-technical users. We will keep it but add another alternative.
The following syntax is currently preferred:
- A task with two custom fields (one by ID and one by name)
customfield_10044: Hello World!
customfield(Revenue): 234
In this example the customfield with the field ID 10044
will have the value Hello World!
and the custom field with the name Revenue
will have the value 234
assigned.
Tasks
- improve syntax
- find solution for : in field names
- add documentation
- inform about need to escape
(
and)
in field names with preceeding\
Considerations
Once we have this feature in place we can also improve the import from Quick Subtasks for Jira and also import the custom fields from the attribute cfield
. This will be handled in a separate issue: #93
Alternatives
Below examples want to assign a value of 800
to a customfield with the name Revenue
:
- this is a task
customfield: FIELD_NAME: FIELD_VALUE
customfield: Renevue: 800
- this is a task
customfield(FIELD_NAME): FIELD_VALUE
customfield(Revenue): 800
Regex
customfield\((?<key>(?:\\\\|\\\)|[^\)])++)\)
Testdata
customfield(Stefan)
customfield(Ein anderers Feld)
customfield(Demo (here\))
customfield(Oh:)
negative Tests:
customfield()
customfields(something)
Conclusions
- Users need to escape the
)
when used in custom field names - We need to find a solution for
:
inside custom field names because currently this would be the end of the attribute name by implementation
Splitter allows to use a pattern instead of a separator string