0

I have a content type with a lot of different fields. Now this content can have (but not always) variations, which have the same fields, but different content.

I don't know how it would be best to organize this on the admin side. I could use child nodes, but if I have children, I'll have an empty parent. Basically what I need is to have multiple sets of the same fields for a content item.

I don't know if this is understandable, you might think of the as product variations or subproducts, here's an example:

Macbook (this only has title + description)
 -- Macbook Air (title + one set of characteristics)
 -- Macbook Pro (title + 2nd set of characteristics)
Mac Mini (title, description, characteristics)
iMac (title, description, characteristics)
0

4 Answers 4

3

As @W.M. said, i will use Conditional Fields module Conditional Fields along with Field Collection Module.

Essentially you will first define collections of fields (this is a kind of grouping of fields that are related. ie retina screen details), and then you can make this fields collections to appear if another field value is set using Field Collection.

2
  • Yes, that did it, field collections let me have an unlimited number of field collection entities, and I just use those as a "variation" Also thanks for emc, as Field groups is a nice module, didn't help me solve my problem, but my field are grouped nicely now :-) Dec 13, 2014 at 18:50
  • Glad to hear that my answer helped you. Please note that for this kind of situations there is not only one path, on most cases you will have 2 or 3 options, it's just a matter of thinking the different use cases and use the one that fits you needs better. Dec 15, 2014 at 13:51
1

I'm not sure what you are describing but according to your example I think Field group is what you need

1

You need the Conditional Fields module. It can show and hide fields upon values of other fields etc. The module can be found here: Conditional fields

0

If I understand the 'question' correctly, take a look at taxonomy - In your example case, Macbook would be the Vocabulary, and Macbook Air and Pro would be the 'Terms' with the fields you want.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.