mirror of
https://github.com/crmeb/CRMEB.git
synced 2026-10-30 06:20:50 +00:00
增加分类数据返回
This commit is contained in:
parent
63ecfbdd92
commit
b4b32a139b
@ -69,9 +69,9 @@ class SystemRouteCateServices extends BaseServices
|
||||
* @email 136327134@qq.com
|
||||
* @date 2023/4/6
|
||||
*/
|
||||
public function getAllList(string $appName = 'outapi', string $field = '*')
|
||||
public function getAllList(string $appName = 'outapi', string $field = '*', string $order = '')
|
||||
{
|
||||
$list = $this->dao->selectList(['app_name' => $appName], $field)->toArray();
|
||||
$list = $this->dao->selectList(['app_name' => $appName], $field, 0, 0, $order)->toArray();
|
||||
return get_tree_children($list);
|
||||
}
|
||||
|
||||
|
||||
@ -68,7 +68,9 @@ class SystemRouteServices extends BaseServices
|
||||
throw new ValidateException('修改的路由不存在');
|
||||
}
|
||||
|
||||
return $routeInfo->toArray();
|
||||
$routeInfo = $routeInfo->toArray();
|
||||
$routeInfo['cate_tree'] = app()->make(SystemRouteCateServices::class)->getAllList($routeInfo['app_name'], '*', 'id asc,sort desc');
|
||||
return $routeInfo;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user