By jjjames on
Is there any way to limit taxonomy terms to be unique so each term can only be used once.
I have a list of codes that I want to be able to assign to users, but each user only gets one code, and each code can only have 1 user. The list of codes would be added as terms to choose from and then would be "disabled" once that code has been used.
Maybe taxonomy isn't the correct approach for this? Any suggestions? I just need to have a premade list of codes to assign (or even auto assign).
Any help appreciated.
Thanks
Comments
Taxonomy exists for classification...
So it's probably not the right choice. By design, taxonomy is meant to allow more than one piece of content to be tagged with the same tag. You'd be fighting against it's design by trying to use it in such a restrictive fashion. But to really help, we'd have to know more about what the codes are supposed to accomplish in the system.
Doug Gough
ImageX Media
Good point thx :) Well so I
Good point thx :) Well so I need to store a list of codes like so:
There are phone numbers which each have their own list of unique per-user access codes. Each number has many codes (in turn, many users). Each code can only be assigned to 1 user. So for instance:
888-432-2345 has access codes: 2532, 5343, 2456, 9844, 3974, 2983, 7643
800-234-5443 has access codes: 2943, 2554, 8747, 2976, 4993, 2348, 3947
I was thinking taxonomy because each phone number could be a Vocabulary, and each code could be a term. But I think you are right about the wrong use. So somewhere I need to be able to paste in a list of several (hundreds) of codes for each phone number. Would be ideal if they were auto parsed by commas or new lines. And then when creating a new user, I need to assign a phone number AND a code. The phone number is not unique to the user, but the code is. So then that code would become un-available for future users.
Thanks alot for your help!