John Molakvoæ
2 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with
11 additions and
48 deletions
-
apps/dashboard/lib/Controller/DashboardApiController.php
-
apps/dashboard/lib/Controller/DashboardController.php
-
apps/dashboard/lib/Controller/LayoutApiController.php
|
|
|
@ -54,25 +54,14 @@ use OCP\IRequest; |
|
|
|
*/ |
|
|
|
class DashboardApiController extends OCSController { |
|
|
|
|
|
|
|
/** @var IManager */ |
|
|
|
private $dashboardManager; |
|
|
|
/** @var IConfig */ |
|
|
|
private $config; |
|
|
|
/** @var string|null */ |
|
|
|
private $userId; |
|
|
|
|
|
|
|
public function __construct( |
|
|
|
string $appName, |
|
|
|
IRequest $request, |
|
|
|
IManager $dashboardManager, |
|
|
|
IConfig $config, |
|
|
|
?string $userId |
|
|
|
private IManager $dashboardManager, |
|
|
|
private IConfig $config, |
|
|
|
private ?string $userId, |
|
|
|
) { |
|
|
|
parent::__construct($appName, $request); |
|
|
|
|
|
|
|
$this->dashboardManager = $dashboardManager; |
|
|
|
$this->config = $config; |
|
|
|
$this->userId = $userId; |
|
|
|
} |
|
|
|
|
|
|
|
/** |
|
|
|
|
|
|
|
@ -46,37 +46,17 @@ use OCP\IRequest; |
|
|
|
#[OpenAPI(scope: OpenAPI::SCOPE_IGNORE)]
|
|
|
|
class DashboardController extends Controller { |
|
|
|
|
|
|
|
/** @var IInitialState */ |
|
|
|
private $initialState; |
|
|
|
/** @var IEventDispatcher */ |
|
|
|
private $eventDispatcher; |
|
|
|
/** @var IManager */ |
|
|
|
private $dashboardManager; |
|
|
|
/** @var IConfig */ |
|
|
|
private $config; |
|
|
|
/** @var IL10N */ |
|
|
|
private $l10n; |
|
|
|
/** @var string */ |
|
|
|
private $userId; |
|
|
|
|
|
|
|
public function __construct( |
|
|
|
string $appName, |
|
|
|
IRequest $request, |
|
|
|
IInitialState $initialState, |
|
|
|
IEventDispatcher $eventDispatcher, |
|
|
|
IManager $dashboardManager, |
|
|
|
IConfig $config, |
|
|
|
IL10N $l10n, |
|
|
|
$userId |
|
|
|
private IInitialState $initialState, |
|
|
|
private IEventDispatcher $eventDispatcher, |
|
|
|
private IManager $dashboardManager, |
|
|
|
private IConfig $config, |
|
|
|
private IL10N $l10n, |
|
|
|
private ?string $userId |
|
|
|
) { |
|
|
|
parent::__construct($appName, $request); |
|
|
|
|
|
|
|
$this->initialState = $initialState; |
|
|
|
$this->eventDispatcher = $eventDispatcher; |
|
|
|
$this->dashboardManager = $dashboardManager; |
|
|
|
$this->config = $config; |
|
|
|
$this->l10n = $l10n; |
|
|
|
$this->userId = $userId; |
|
|
|
} |
|
|
|
|
|
|
|
/** |
|
|
|
|
|
|
|
@ -31,21 +31,15 @@ use OCP\IConfig; |
|
|
|
use OCP\IRequest; |
|
|
|
|
|
|
|
class LayoutApiController extends OCSController { |
|
|
|
/** @var IConfig */ |
|
|
|
private $config; |
|
|
|
/** @var string */ |
|
|
|
private $userId; |
|
|
|
|
|
|
|
public function __construct( |
|
|
|
string $appName, |
|
|
|
IRequest $request, |
|
|
|
IConfig $config, |
|
|
|
$userId |
|
|
|
private IConfig $config, |
|
|
|
private ?string $userId, |
|
|
|
) { |
|
|
|
parent::__construct($appName, $request); |
|
|
|
|
|
|
|
$this->config = $config; |
|
|
|
$this->userId = $userId; |
|
|
|
} |
|
|
|
|
|
|
|
/** |
|
|
|
|