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.
A drupal_alter or simple notice of when nodequeues are saved, and a hook called when a nodequeue is deleted, would be useful for modules wanting to react to that.
My use case happens to be a smartqueue per nodequeue module, but i'm sure there are saner reasons also.
Comment | File | Size | Author |
---|---|---|---|
#1 | nodequeue.admin_.inc_.patch | 448 bytes | josephcheek |
Comments
Comment #1
josephcheekHere's half of it, a hook that fires when a subqueue is saved.
hook_nodequeue_saved($sqid, $nodes)
Comment #2
josephcheekbtw, there already is an undocumented hook_nodequeue_save_subqueue_order_alter($sqid, $nodes) that fires before the subqueue is saved, allowing code to alter the nodes before they are saved.
Comment #3
fizk CreditAttribution: fizk commentedWe currently have the following hooks:
./nodequeue.module: module_invoke_all('nodequeue_delete', $qid);
./nodequeue.module: module_invoke_all('nodequeue_add', $subqueue->sqid, $nid);
./nodequeue.module: module_invoke_all('nodequeue_remove', $sqid, $node->nid);
./nodequeue.module: module_invoke_all('nodequeue_swap', $subqueue->sqid, $nid);
./nodequeue.module: return module_invoke_all('nodequeue_info');
./includes/nodequeue.admin.inc: module_invoke_all('nodequeue_update', $qid, $sqid);