I might be going at this the wrong way, so whatever advice is welcome.
I have a person table and a phoneNumber table. A Person can have multiple PhoneNumbers. Now I want to mark one (and only one) of those phoneNumbers as 'preferred'. Also I would like the edit form to show radio buttons next to each phone number so that the user can select one number as preferred.
Initially, I created a column in Person called 'preferred_phone_id' which was a fk to phoneNumber.id.
The problem comes in the form rendering. I can't seem to render individual radio button items (in the same group) so I can't place the radio button of my choosing 'next' to the input fields for the relevant number and still have the toggle work. So maybe that's not the best approach.
Any ideas on the best way to do this?
thanks,