讨论数量:
可以试一下这种办法
protected function registerGlobalFunctions()
{
$files = glob($this->app->path('Support/*helpers.php'));
foreach ($files as $file) {
require_once $file;
}
}
服务中注册引导一下就可以了 AppServiceProvider
推荐文章: