function nodeorder_node_load in Node Order 7
Implements hook_node_load().
File
- ./
nodeorder.module, line 775 - Nodeorder module.
Code
function nodeorder_node_load($nodes, $types) {
$query = db_select('taxonomy_index', 't')
->fields('t', array(
'weight',
'nid',
'tid',
))
->condition('nid', array_keys($nodes), 'IN');
$result = $query
->execute();
foreach ($result as $record) {
$nodes[$record->nid]->nodeorder[$record->tid]['weight'] = $record->weight;
}
}