This repository has been archived on 2024-04-08. You can view files and clone it, but cannot push or open issues or pull requests.
khosb/application/classes/Controller/Account.php
2013-10-10 13:44:53 +11:00

34 lines
827 B
PHP

<?php defined('SYSPATH') or die('No direct access allowed.');
/**
* This class provides account management
*
* @package OSB
* @category Controllers
* @author Deon George
* @copyright (c) 2009-2013 Open Source Billing
* @license http://dev.osbill.net/license.html
*/
class Controller_Account extends Controller_TemplateDefault {
public function action_group() {
$output = '';
$cg = $this->ao->group->find_all();
foreach ($cg as $go) {
$output .= sprintf('Group %s: %s<br/>',$go->id,$go->display('name'));
foreach ($go->list_childgrps(TRUE) as $cgo)
$output .= sprintf('- %s: %s (%s)<br/>',$cgo->id,$cgo->display('name'),$cgo->parent_id);
$output .= sprintf('END Group %s<br/><br/>',$go->id);
}
Block::add(array(
'title'=>'Group Structure',
'body'=>$output,
));
}
}
?>