Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/circles.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/lib/Api
diff options
context:
space:
mode:
authorJoas Schilling <coding@schilljs.com>2018-10-18 12:35:11 +0300
committerJoas Schilling <coding@schilljs.com>2018-10-18 12:35:11 +0300
commit5b786ceacb520e9a902f95731120f7ecb75b412e (patch)
treed6cf526d97901c6099ff53e5c060e946b75c68dd /lib/Api
parent57fcf4fe40bd42ccbc2923639f4c32ce8f56fbc9 (diff)
Make the link to circles absolute
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'lib/Api')
-rw-r--r--lib/Api/v1/Circles.php19
1 files changed, 17 insertions, 2 deletions
diff --git a/lib/Api/v1/Circles.php b/lib/Api/v1/Circles.php
index 64f4c597..48b2bd86 100644
--- a/lib/Api/v1/Circles.php
+++ b/lib/Api/v1/Circles.php
@@ -458,7 +458,22 @@ class Circles {
/**
- * Circles::generateLink();
+ * Circles::generateAbsoluteLink();
+ *
+ * Returns the absolute link to get access to a local circle.
+ *
+ * @param string $circleUniqueId
+ *
+ * @return string
+ */
+ public static function generateAbsoluteLink($circleUniqueId) {
+ return \OC::$server->getURLGenerator()
+ ->linkToRouteAbsolute('circles.Navigation.navigate') . '#' . $circleUniqueId;
+ }
+
+
+ /**
+ * Circles::generateRemoteLink();
*
* Returns the link to get access to a remote circle.
*
@@ -529,4 +544,4 @@ class Circles {
return $c->query(CirclesService::class)
->getFilesForCircles($circleUniqueIds);
}
-} \ No newline at end of file
+}