-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #32561 from nextcloud/port/vue-personal-federation
- Loading branch information
Showing
19 changed files
with
289 additions
and
325 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,7 @@ | |
* @author Jos Poortvliet <[email protected]> | ||
* @author Julius Härtl <[email protected]> | ||
* @author Morris Jobke <[email protected]> | ||
* @author Carl Schwan <[email protected]> | ||
* | ||
* @license GNU AGPL version 3 or any later version | ||
* | ||
|
@@ -27,31 +28,34 @@ | |
|
||
use OCA\FederatedFileSharing\FederatedShareProvider; | ||
use OCP\AppFramework\Http\TemplateResponse; | ||
use OCP\AppFramework\Services\IInitialState; | ||
use OCP\IL10N; | ||
use OCP\IUserSession; | ||
use OCP\IURLGenerator; | ||
use OCP\Settings\ISettings; | ||
|
||
class Personal implements ISettings { | ||
|
||
/** @var FederatedShareProvider */ | ||
private $federatedShareProvider; | ||
/** @var IUserSession */ | ||
private $userSession; | ||
/** @var IL10N */ | ||
private $l; | ||
/** @var \OC_Defaults */ | ||
private $defaults; | ||
private FederatedShareProvider $federatedShareProvider; | ||
private IUserSession $userSession; | ||
private IL10N $l; | ||
private \OC_Defaults $defaults; | ||
private IInitialState $initialState; | ||
private IURLGenerator $urlGenerator; | ||
|
||
public function __construct( | ||
FederatedShareProvider $federatedShareProvider, # | ||
IUserSession $userSession, | ||
IL10N $l, | ||
\OC_Defaults $defaults | ||
\OC_Defaults $defaults, | ||
IInitialState $initialState, | ||
IURLGenerator $urlGenerator | ||
) { | ||
$this->federatedShareProvider = $federatedShareProvider; | ||
$this->userSession = $userSession; | ||
$this->l = $l; | ||
$this->defaults = $defaults; | ||
$this->initialState = $initialState; | ||
$this->urlGenerator = $urlGenerator; | ||
} | ||
|
||
/** | ||
|
@@ -71,6 +75,14 @@ public function getForm() { | |
'color' => $this->defaults->getColorPrimary(), | ||
'textColor' => "#ffffff", | ||
]; | ||
|
||
$this->initialState->provideInitialState('color', $this->defaults->getColorPrimary()); | ||
$this->initialState->provideInitialState('textColor', '#fffff'); | ||
$this->initialState->provideInitialState('logoPath', $this->defaults->getLogo()); | ||
$this->initialState->provideInitialState('reference', $url); | ||
$this->initialState->provideInitialState('cloudId', $cloudID); | ||
$this->initialState->provideInitialState('docUrlFederated', $this->urlGenerator->linkToDocs('user-sharing-federated')); | ||
|
||
return new TemplateResponse('federatedfilesharing', 'settings-personal', $parameters, ''); | ||
} | ||
|
||
|
Oops, something went wrong.