think
think copied to clipboard
请问如何获取所有路由或控制器?
php think route:list
php think route:list
是我没描述清楚,我是想知道怎么在控制器里获取到所有的路由或所有的控制器。
在控制器里可以调用命令的。实在不行你跟踪代码看看 route:list 怎么实现的即可
------------------ 原始邮件 ------------------ 发件人: "top-think/think" @.>; 发送时间: 2021年7月29日(星期四) 中午12:15 @.>; @.@.>; 主题: Re: [top-think/think] 请问如何获取所有路由或控制器? (#1084)
php think route:list
是我没描述清楚,我是想知道怎么在控制器里获取到所有的路由或所有的控制器。
— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.
在控制器里可以调用命令的。实在不行你跟踪代码看看 route:list 怎么实现的即可 … ------------------ 原始邮件 ------------------ 发件人: "top-think/think" @.>; 发送时间: 2021年7月29日(星期四) 中午12:15 @.>; @.@.>; 主题: Re: [top-think/think] 请问如何获取所有路由或控制器? (#1084) php think route:list 是我没描述清楚,我是想知道怎么在控制器里获取到所有的路由或所有的控制器。 — You are receiving this because you commented. Reply to this email directly, view it on GitHub, or unsubscribe.
控制器里调用命令可以赋值的吗,我不是很清楚。不过我找到 getRuleList 可以获取到路由列表。
可以的,查看控制器调用命令部分