24 lines
594 B
PHP
24 lines
594 B
PHP
<?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 PageController {
|
|
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);
|
|
}
|
|
}
|