This should be quick and simple if you already know views API -

I need a new views api argument for the node relativity module. The module stores relationships in a single table (relativity) which has 2 columns, nid and parent_nid. This relativity.nid field in this situation is the child node. I want to be able to pass a node id to a view as an argument and get back a list of all nodes which are parents of that node.

In other words, select all the records in the relativity table which have nid equal to the argument, and build a view with the parent_nid's.

There is already the opposite functionality (send parent id, get children) as an argument in the module.

I figure this should be really easy for someone who is good with views API, let me know how much you want to solve this last issue so I can get a site up and going...

Comments

joachim’s picture

Like you say, the module already has an argument that goes the other way -- feed it the parent node ID and you list the children.
You could probably do it yourself by copying & pasting and changing the parent bits to child and vice versa :)
Otherwise, I can do it for you for 20 GPB.

andb’s picture

With some guidance from Merlinofchaos, this issue has been resolved. I will submit the changes as a patch to the module.