Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Being that it has these functions, and in places like node add pages it'll likely already used that function, maintaining own separate query/cache seems unideal. http://gyazo.com/fe4d98642cf76fd9c434f8a1075b29aa
Comment | File | Size | Author |
---|---|---|---|
noderelationships.inc_get_nodereferences.patch | 2.14 KB | hefox |
Comments
Comment #1
markus_petrux CreditAttribution: markus_petrux commentedNope, this cannot be done. If CCK inners change, we can adapt with a patch, but we need a method to bypass content_types(). See the comment in function noderelationships_get_relationships():
Please, re-open if there's any problem with the current code, but if not, I would not apply any patch here.
Comment #2
hefox CreditAttribution: hefox commentedSorry, should have seen that.
What about a patch so just hook_content_extra_fields uses a function/query similair to current one, and node relationships in general uses ^?
Or perhaps add some caching? Actually, caching might be the best performance wise, as won't even need to process the data since it can just grab it.
From what I saw/recall, it's doing that query every node form, which doesn't seem that bad since it's just that node form, but on a heavy site with many users + a lot of content addition, it's becomes a problem.
Comment #3
markus_petrux CreditAttribution: markus_petrux commentedHonestly, due to lack of time, I'm not sure I'll be able to review such a change, because it is not trivial.
I'm setting the project status properly.