user added select values
user added select values
Description of problem:
I intend to have an editor field where the user can add email addresses. These will not be stored in a separate table from which the options can be retrieved. These will be stored the table I'm editing which will store these as a@example.com;b@example.com. I initially tried doing this with select2 using its tags feature, but the data which is already in the table isn't shown when I bring up the editor modal. (The table already has single email addresses as text fields, but I want to add the feature allowing the user to add or create multiple addresses)
I want to create a link to a test case, but first I want to verify that select2 is an ok way to do this. Most of the selects in my application are select2.
I looked briefly at the tags data type, but I don't think this works for my use case.
Assuming select2 is fine, where is the best place to find a live version I can clone to show my problem?
Answers
The Select2 plugin for Editor has a
separatoroption that might be useful here. If you have a string which has multiple values delimited by a specific character, use that option to have it split the string up into the individual parts.Here is a Select2 example in Editor that you could use as your base.
Do you need the Select2 lookup feature here (since you aren't storing it, there is nothing to lookup)? Or is it just a way to combine multiple values into a single string?
Allan