Both the default and other endpoints display formats don't have any settings.
It would be nice to have the possibility to drill down relations some more.
graphapi.module has a lot settings so please tell me how to do ie a depth graph for both dummy field as graphapi and what more features are needed. I'll provide for the patch :-)


| Comment | File | Size | Author |
|---|---|---|---|
| graphapi-relation-field-settings.png | 26.84 KB | clemens.tolboom | |
| graphapi-relation-depth-1.png | 47.43 KB | clemens.tolboom |
Comments
Comment #1
naught101 commentedYep. Might need to add some API functions for that too. Were there any other config settings apart from depth that you could think of?
Also, how do you want the data from the 2nd level relations to be stored? I'm still not completely familiar with how graphAPI deals with the data, but I'll try to look into it soon.
Comment #2
naught101 commentedHrm.. I'm now thinking that this might actually be a relation-graphAPI specific feature. I can't imagine any other formatters needing this data, can you?
I wonder if we shouldn't just add this to graphapi_relation_field_formatter_view()? (not trying to palm this off on you, promise! :D )
Comment #3
clemens.tolboomThe data should be similar to include/graph.inc ... graphapi suffers #1209426: Multiple links from A to B are not supported
Some use cases
Depth example:
- Complete graph entities as a list
- Show all entities within distance 2 : related to #1186228: Shortest Path Algorithm
Filtered example: what projects are related to current project
- Show project entities based on relation model : project - issue - comment - user - comment - issue - project
GraphAPI is a little useless without a depth.
Filtering is way more complex but would be nice i.e. for discovering clusters.
Comment #4
clemens.tolboomPlease tell me how to get ie a depth 2 graph.
Relates to #1186228: Shortest Path Algorithm
Comment #5
naught101 commentedUm. Basically that would require you to iterate over all the relations in the dummy field (ie. $items), and run relation_get_relations() on each one. I'm not sure what to do with that data once you have it - stick it straight in the graph arrays, I guess.
Comment #6
clemens.tolboomDarn ... so no API for that ... :(
Comment #7
naught101 commentedseparate feature request? :P
Comment #8
clemens.tolboomFeature request filed under #1221370: Please write a decent relation.api.php
When that one is fixed we could fix this ;-)
Comment #9
naught101 commentedAs far as I can tell, this is Graph API specific - ie. there are no other formatters that would benefit from multiple depth relations, so let's put this in graphapi_relation_field_formatter_view(). I will start work on it as soon as I can.
Comment #10
naught101 commentedComment #11
clemens.tolboomComment #12
clemens.tolboom