Hello,

I would like to be able to create some nodes that are related to the a node the user is looking at. For example a user would look at node A and would like to add a review.

This module could be used to insert the form of the 'review' node type directly into the 'source' node. The nodereference link would be added directly to the "review" node but the select field would not be visible when this form is in 'embedded' mode.

Would you be interested in adding this feature to your module? I might be willing to sponsor the developpement of this feature.

Comments

Tamar Badichi-Levy’s picture

This is an interesting feature. I hope I understand you correctly.

The nodereference link would be added directly to the "review" node but the select field would not be visible when this form is in 'embedded' mode.

Do you mean that when viewing a node there will be another form in the page from a related content type? where it will be possible to choose either an existing review or create a new review using the form?

patchak’s picture

Hey there,

I mean that we could add another related node, directly from the node that we are looking at. We should then 'hide' the nodereference field, since the node form is embedded directly into the source node.

Thanks,
Patchak

Tamar Badichi-Levy’s picture

OK,
Let's think if a simple example that may explain the functionality.
Let's say we have a scientific paper content type with review as a related child content type. Any user that reads a paper would have the possibility to fill and submit a review about this paper. In order to achieve this functionality we need to call drupal_get_form of the related content type when viewing the parent content type. That can be done.
However, I'm sorry that I'm a little slow here but I don't understand the nodereference field hiding/showing functionality. The way I get it, nodereference does not deal with content type relations, but here you suggest to create a relation between two nodes: one (the parent) in a view mode and the other (a child cck type) in an edit mode.

patchak’s picture

Well what I mean is that the second node will be linked to the parent one, with node reference. But since the form is directly displayed under another node, then we don,t need to see the noderefence select field, as the child node would automatically get the parent node as it's nodereference value.

Is is clearer?
Patchak

Tamar Badichi-Levy’s picture

Not entirely clear yet. The purpose of subforms is to be able to include several content types' forms in one form. If you need to put a form at the end of a certain viewed node you can simply add the form with no need to use subforms (using hook_nodeapi). That will make it much easier. If there is no need to use subforms and no node relativity needs to be set then your idea is great for another new module or to extend the existing node reference module. If you believe that there is a place for subforms and relativity deployment in your idea please explain how you will use them.

Best wishes, Ofir.