feat: 分离前端列表
This commit is contained in:
@@ -14,6 +14,7 @@ declare(strict_types=1);
|
||||
|
||||
namespace Catch;
|
||||
|
||||
use Catch\Support\Module\Installer;
|
||||
use Illuminate\Support\Facades\File;
|
||||
use Illuminate\Support\Str;
|
||||
|
||||
@@ -360,4 +361,20 @@ class CatchAdmin
|
||||
{
|
||||
return Str::replaceFirst(base_path(), '.', $path);
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* @param string $module
|
||||
* @return Installer
|
||||
*/
|
||||
public static function getModuleInstaller(string $module): Installer
|
||||
{
|
||||
$installer = self::getModuleServiceProviderNamespace($module).'Installer';
|
||||
|
||||
if (class_exists($installer)) {
|
||||
return app($installer);
|
||||
}
|
||||
|
||||
throw new \RuntimeException("Installer [$installer] Not Found");
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user