It would be great if, in addition to Textfield, Select list, Single checkbox, and Textarea, the Reference field type could be used.

Comments

bronzehedwick created an issue. See original summary.

marassa’s picture

Bump bump. I have a use case very similar to "My Team" in the module home page but the second (person name) text sub-field should be a reference to a content type with "Create referenced entities if they don't already exist".
Also, having the first (role) sub-field defined as a taxonomy reference would be much neater than hard-coding an untranslatable list of values into the field definition - a multilingual show stopper.
I might be even willing to pay for this functionality if I had a vague idea of how much it could cost - have no skills to do it myself.

chi’s picture

marassa’s picture

Thanks, I already found a closed issue where you explain why this is not going to happen. I will look into Field Collection and Paragraphs too.
PS To prevent people from inadvertently digging up the dead horse again and again, it might make sense to close this issue and re-open that one (https://www.drupal.org/node/2804917), so that newcomers won't bump it or bring it up again? I didn't think of browsing closed issues when I saw an open one on the subject.

chi’s picture

"Open" status of the issue means that maintainer needs to resolve it (either to fix or decline). There is no difficulty in searching closed issues. I understand that reference sub field is really desired feature for many sites. I think the best approach would be creating a separate module that extends Double field and Entity reference modules. Meanwhile for simple cases like yours when configuration options are not needed I suggest creating custom field type as shown in the Lullabot's article. It would take you 1-2 hr on development. Of course this implies having programming skills and knowledge of Drupal field API.

marassa’s picture

I see, thanks for your advice. I just tried Field Collection and it seems to do what I want, just need to iron out some presentation quirks (like sub-fields showing on separate lines and not side-by-side) which seems solvable with plain CSS.
I have a solid and diverse programming background, just don't know a thing about PHP and/or Drupal internals and at this moment in time I'd rather not learn another language if possible ;)