feat: allow global settings as fallback when user has not defined any
This commit is contained in:
25
lib/Settings/AdminSettings.php
Normal file
25
lib/Settings/AdminSettings.php
Normal file
@ -0,0 +1,25 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace OCA\PrideFlags\Settings;
|
||||
|
||||
use OCA\PrideFlags\AppConstants;
|
||||
use OCP\AppFramework\Http\TemplateResponse;
|
||||
use OCP\Settings\ISettings;
|
||||
use OCP\Util;
|
||||
|
||||
class AdminSettings implements ISettings {
|
||||
public function getForm(): TemplateResponse {
|
||||
Util::addScript(AppConstants::APP_ID, 'pride-settings-global');
|
||||
return new TemplateResponse(AppConstants::APP_ID, 'server-settings', []);
|
||||
}
|
||||
|
||||
public function getSection(): string {
|
||||
return AppConstants::APP_ID;
|
||||
}
|
||||
|
||||
public function getPriority(): int {
|
||||
return 50;
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user