Taxonomy fields in autocomplete
- This topic has 4 replies, 2 voices, and was last updated 8 years, 9 months ago by .
Viewing 4 reply threads
Viewing 4 reply threads
- You must be logged in to reply to this topic.
Home › Forums › Autocomplete › Taxonomy fields in autocomplete
Hi Alexander,
are there any restrictions on taxonomy fields using autocomplete?
Many thanks in advance
Aglika
Hi,
I’m not 100% sure I understand your question, but the AC-plugin can only be used on single line of text columns.
Do you maybe mean to set a taxonomy field in the “setFields” parameter?
Alexander
Hi,
I like to use a taxonomy field in the “showField” and “setFields”.
Regards
Aglika
Sorry for the delay – here is a snippet you can use. Add this to the Custom JS:
function parseSingleChoiceManagedMetadata(val){
return '"'+String(val).split(";#")[1]+'"';
}
Then specify the function name in the “parseFunction” parameter like this:
...
...
"setFields":[{
"fromFIN":["ManagedMetadata"],
"joinBy":"",
"toFIN":"ManagedMetadata",
"parseFunction":"parseSingleChoiceManagedMetadata",
"skipIfEmpty":false
}]
Alexander
Many thanks!
Aglika