| 1 | <?php |
| 2 | |
| 3 | //XXX duplicate to get_node_commanders, |
| 4 | //only one can survive;) |
| 5 | |
| 6 | function smarty_function_get_node_commanders2($brawco,&$smarty) { |
| 7 | global $db,$node; |
| 8 | $node_id=$node['node_id']; |
| 9 | $set=$db->query("select node_permission,users.login from node_access left join users on node_access.user_id=users.user_id where node_id='$node_id' and node_permission!='' order by node_permission"); |
| 10 | |
| 11 | while ($set->next()) { |
| 12 | $commanders[$set->getString('node_permission')][]=$set->getString('login'); |
| 13 | } |
| 14 | |
| 15 | $smarty->assign('get_node_commanders2',$commanders); |
| 16 | // $smarty->assign('masters',$commanders['master']); |
| 17 | // $smarty->assign('ops',$commanders['op']); |
| 18 | // $smarty->assign('access',$commanders['access']); |
| 19 | // $smarty->assign('bans',$commanders['ban']); |
| 20 | // $smarty->assign('silence',$commanders['silence']); |
| 21 | // $smarty->assign('execute',$commanders['execute']); |
| 22 | |
| 23 | } |
| 24 | |
| 25 | ?> |
| 26 | |
| 27 | |
| 28 | |