diff --git a/apps/files/lib/Controller/ViewController.php b/apps/files/lib/Controller/ViewController.php index ed3fff223f..688db41f8b 100644 --- a/apps/files/lib/Controller/ViewController.php +++ b/apps/files/lib/Controller/ViewController.php @@ -248,6 +248,8 @@ class ViewController extends Controller { $nav->assign('quota', $storageInfo['quota']); $nav->assign('usage_relative', $storageInfo['relative']); + $nav->assign('webdav_url', \OCP\Util::linkToRemote('dav/files/' . $user)); + $contentItems = []; // render the container content for every navigation item diff --git a/apps/files/templates/appnavigation.php b/apps/files/templates/appnavigation.php index b443671498..aaf62f1d6b 100644 --- a/apps/files/templates/appnavigation.php +++ b/apps/files/templates/appnavigation.php @@ -42,7 +42,7 @@ + value=""/> t('Use this address to access your Files via WebDAV', array(link_to_docs('user-webdav')))); ?> diff --git a/apps/files/tests/Controller/ViewControllerTest.php b/apps/files/tests/Controller/ViewControllerTest.php index f07af2a2fe..30d7bdfdc6 100644 --- a/apps/files/tests/Controller/ViewControllerTest.php +++ b/apps/files/tests/Controller/ViewControllerTest.php @@ -147,7 +147,7 @@ class ViewControllerTest extends TestCase { $nav->assign('usage', '123 B'); $nav->assign('quota', 100); $nav->assign('total_space', '100 B'); - //$nav->assign('webdavurl', ''); + $nav->assign('webdav_url', 'http://localhost/remote.php/dav/files/testuser1/'); $nav->assign('navigationItems', [ 'files' => [ 'id' => 'files',