add categories customization
This commit is contained in:
parent
63b32ea40f
commit
89ca510897
5 changed files with 354 additions and 216 deletions
|
|
@ -20,7 +20,9 @@
|
|||
namespace OCA\SideMenu\Controller;
|
||||
|
||||
use OCA\SideMenu\AppInfo\Application;
|
||||
use OCA\SideMenu\Service\Color;
|
||||
use OCA\SideMenu\Service\ConfigProxy;
|
||||
use OCA\SideMenu\Service\LangRepository;
|
||||
use OCP\AppFramework\Controller;
|
||||
use OCP\AppFramework\Http\Attribute\FrontpageRoute;
|
||||
use OCP\AppFramework\Http\Attribute\NoCSRFRequired;
|
||||
|
|
@ -30,7 +32,6 @@ use OCP\AppFramework\Http\RedirectResponse;
|
|||
use OCP\IConfig;
|
||||
use OCP\IRequest;
|
||||
use OCP\IURLGenerator;
|
||||
use OCA\SideMenu\Service\Color;
|
||||
|
||||
class AdminSettingController extends Controller
|
||||
{
|
||||
|
|
@ -41,6 +42,7 @@ class AdminSettingController extends Controller
|
|||
protected ConfigProxy $configProxy,
|
||||
protected IURLGenerator $urlGenerator,
|
||||
protected Color $color,
|
||||
protected LangRepository $langRepository,
|
||||
) {
|
||||
parent::__construct($appName, $request);
|
||||
}
|
||||
|
|
@ -65,6 +67,7 @@ class AdminSettingController extends Controller
|
|||
$excludedKeys = [
|
||||
'cache',
|
||||
'cache-categories',
|
||||
'langs',
|
||||
];
|
||||
|
||||
foreach ($keys as $key) {
|
||||
|
|
@ -204,6 +207,8 @@ class AdminSettingController extends Controller
|
|||
}
|
||||
}
|
||||
|
||||
$config['langs'] = $this->langRepository->getUsedLangs();
|
||||
|
||||
return new JSONResponse($config);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue