diff options
author | John Molakvoæ <skjnldsv@protonmail.com> | 2023-06-30 11:19:21 +0200 |
---|---|---|
committer | John Molakvoæ <skjnldsv@protonmail.com> | 2023-07-05 16:20:34 +0200 |
commit | e3bac437c225f28bc6a9ca34c4fc33c936b00513 (patch) | |
tree | d58c9153cff230cf4850092f84aeafa19de448ed /apps/files/lib | |
parent | 7929ad4a9303d4f184e56f95fc89347519a164e4 (diff) | |
download | nextcloud-server-e3bac437c225f28bc6a9ca34c4fc33c936b00513.tar.gz nextcloud-server-e3bac437c225f28bc6a9ca34c4fc33c936b00513.zip |
chore: remove old favorites view
Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>
Diffstat (limited to 'apps/files/lib')
-rw-r--r-- | apps/files/lib/AppInfo/Application.php | 9 | ||||
-rw-r--r-- | apps/files/lib/Controller/ApiController.php | 14 | ||||
-rw-r--r-- | apps/files/lib/Controller/ViewController.php | 29 |
3 files changed, 0 insertions, 52 deletions
diff --git a/apps/files/lib/AppInfo/Application.php b/apps/files/lib/AppInfo/Application.php index 0d366e66fe8..7021769752e 100644 --- a/apps/files/lib/AppInfo/Application.php +++ b/apps/files/lib/AppInfo/Application.php @@ -172,15 +172,6 @@ class Application extends App implements IBootstrap { 'name' => $l10n->t('Recent') ]; }); - \OCA\Files\App::getNavigationManager()->add(function () use ($l10n) { - return [ - 'id' => 'favorites', - 'appname' => 'files', - 'script' => 'simplelist.php', - 'order' => 5, - 'name' => $l10n->t('Favorites'), - ]; - }); } private function registerHooks(): void { diff --git a/apps/files/lib/Controller/ApiController.php b/apps/files/lib/Controller/ApiController.php index fd0f3bdf261..f8911c4d104 100644 --- a/apps/files/lib/Controller/ApiController.php +++ b/apps/files/lib/Controller/ApiController.php @@ -384,20 +384,6 @@ class ApiController extends Controller { } /** - * Get sorting-order for custom sorting - * - * @NoAdminRequired - * - * @param string $folderpath - * @return string - * @throws \OCP\Files\NotFoundException - */ - public function getNodeType($folderpath) { - $node = $this->userFolder->get($folderpath); - return $node->getType(); - } - - /** * @NoAdminRequired * @NoCSRFRequired */ diff --git a/apps/files/lib/Controller/ViewController.php b/apps/files/lib/Controller/ViewController.php index 149ce242502..43be43aa116 100644 --- a/apps/files/lib/Controller/ViewController.php +++ b/apps/files/lib/Controller/ViewController.php @@ -202,37 +202,8 @@ class ViewController extends Controller { $favElements['folders'] = []; } - $collapseClasses = ''; - if (count($favElements['folders']) > 0) { - $collapseClasses = 'collapsible'; - } - - $favoritesSublistArray = []; - - $navBarPositionPosition = 6; - foreach ($favElements['folders'] as $favElement) { - $element = [ - 'id' => str_replace('/', '-', $favElement), - 'dir' => $favElement, - 'order' => $navBarPositionPosition, - 'name' => basename($favElement), - 'icon' => 'folder', - 'params' => [ - 'view' => 'files', - 'dir' => $favElement, - ], - ]; - - array_push($favoritesSublistArray, $element); - $navBarPositionPosition++; - } - $navItems = \OCA\Files\App::getNavigationManager()->getAll(); - // add the favorites entry in menu - $navItems['favorites']['sublist'] = $favoritesSublistArray; - $navItems['favorites']['classes'] = $collapseClasses; - // parse every menu and add the expanded user value foreach ($navItems as $key => $item) { $navItems[$key]['expanded'] = $this->config->getUserValue($userId, 'files', 'show_' . $item['id'], '0') === '1'; |