initial commit
This commit is contained in:
23
lib/Controller/SettingsController.php
Normal file
23
lib/Controller/SettingsController.php
Normal file
@ -0,0 +1,23 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace OCA\PrideFlags\Controller;
|
||||
|
||||
use OCA\PrideFlags\Settings\AppSettings;
|
||||
use OCP\IRequest;
|
||||
use OCP\IConfig;
|
||||
//use OCP\Framework\Controller;
|
||||
use OCP\Framework\Http\Response;
|
||||
|
||||
class SettingsController {
|
||||
public function __construct($appName, IRequest $request, AppSettings $settings) {
|
||||
parent::__construct($appName, $request);
|
||||
}
|
||||
public function get(): JSONResponse {
|
||||
return $this->settings->getAll();
|
||||
}
|
||||
public function set(string $folderVariant, string $buttonVariant): JSONResponse {
|
||||
return $this->settings->set($folderVariant, $buttonVariant);
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user