method fTreat documentation in bbn\User\Permissions
function(array $tree, $parent = false)
{
$res = [];
foreach ($tree as $i => $t){
$code = $t['type'] === 'dir' ? X::basename($t['name']).'/' : X::basename($t['name'], '.php');
$text = $t['type'] === 'dir' ? X::basename($t['name']) : X::basename($t['name'], '.php');
$o = [
'code' => $code,
'text' => $text
];
if ($t['type'] === 'file') {
$o['type'] = 'file';
}
if (!empty($t['items'])) {
$o['items'] = self::fTreat($t['items'], $o['code']);
}
array_push($res, $o);
}
return $res;
}
BBN is a suite of PHP and JS libraries and VueJS components - all open-source! bbn.io, build applications, the quick way
This website uses cookies to ensure you get the best experience on our website.
© 2011-2025
BBN Solutions