priority menu item

This commit is contained in:
2024-09-24 14:57:25 +03:00
parent a48088581f
commit cb2c719b1b
12 changed files with 29 additions and 14 deletions

View File

@ -32,7 +32,8 @@ class AdminThemeService
public function setActiveAdminTheme(string $theme): void
{
$active_admin_theme = Option::where("key", "active_admin_theme")->first();
$active_admin_theme->value = $theme;
Debug::prn(getConst($theme));
$active_admin_theme->value = getConst($theme);
$active_admin_theme->save();
}
@ -44,6 +45,7 @@ class AdminThemeService
public function getAdminThemeInfo(string $theme): false|array|string
{
$info = [];
$theme = getConst($theme);
$info['path'] = $theme;
if (file_exists($theme . "/manifest.json")){
$manifest = file_get_contents($theme . "/manifest.json");