I have trouble expressing my problem in one single sentence, but I think what I would like is to select only taxonomy entries which are available only in the parent node, referenced via a node reference.

I am currently trying to patch together a "Living Stories" (Youtube video, summary of the features) feature. One of the requirements are themes within a story.

For now I have modelled this as several nodes:

Living Story
The living story, this I will add a template, panel or similar to style it and add appropriate views
Living Story Update
Basically a story which have a nodereference field for selecting the Living Story to update.
Living Story Source
Nodes with data/donwloadables/graphics, and sources for those. As per requirements.

Now, the themes are like sub stories to the main Living Story. I originally were thinking of creating these by using Taxonomy and Hierarchical Select. When creating a Living Story the user would have to copy the title into a new root node in the selected Taxonomy.

Themes would be added as sub-terms of that root node.

But, it quickly dawned upon me that this would not work if there is a large number of living stories, it is irritating to look through lists longer than a few tenfolds.

My next idea is to create a node type "Living Story Theme" and let those have a nodereference field for selecting which "Living Story" they are a part of. Then in the "Living Story Update" I would have a nodereference field for selecting which "Living Story Theme" the update is part of (in addition to the Living Story).

The thing is that even if I create a view which just lets you select a subset of the "Living Story Themes" based on the "Living Story" selected, I can't see how I will pass that argument into the view upon node creation, since no theme has been selected yet.

One solution would be to add a link which uses one of the modules for passing info through the url to the node creation form, filling in the value of the "Living Story" at once; but still I don't have access to that in my view.

Next step would be to add the "Add update" link under each theme, or allow the user to select which theme to update before getting to the node create form. And if I use node templates I can't see how to pack them in from the Features module (now there is a new module idea for enterprising coders).

Any clues on where to go now, would be welcome.

Comments

pkej’s picture

Replying to say that Content Taxonomy has, IIRC, a way to limit which part of a taxonomy which is available, but I need a dynamic binding for this, not a static one defined in the node type.

Somewhat related issues in the queue of Content Taxonomy: #524098: PHP code for selecting parent: How-to? #460346: Pass variables to 'Advanced PHP Code' #652112: Advanced PHP code for selecting new parent

And of course: #450720: How to inherit the content of a parent node?.

But I'd like to do something similar with taxonomy.

Paul K Egell-Johnsen

pkej’s picture

Just for my own reference:

http://drupal.org/node/452472 is and http://drupal.org/node/504440, but they are more geared towards copying all the info into the child node, but not limiting the taxonomy sub-tree available.

I do think, however, that together with templates for the node create of the node type, I will be able to use the above to make it work as I wish, but, how do you distribute the template with features...?

Paul K Egell-Johnsen

pkej’s picture

It might be that triggers are what I need to use, and let themes be nodes. http://drupal.org/node/864674#comment-3252512

Paul K Egell-Johnsen