aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Widget
diff options
context:
space:
mode:
Diffstat (limited to 'Zotlabs/Widget')
-rw-r--r--Zotlabs/Widget/Cdav.php5
-rw-r--r--Zotlabs/Widget/Hq_controls.php26
2 files changed, 29 insertions, 2 deletions
diff --git a/Zotlabs/Widget/Cdav.php b/Zotlabs/Widget/Cdav.php
index 60a860f93..589f915c5 100644
--- a/Zotlabs/Widget/Cdav.php
+++ b/Zotlabs/Widget/Cdav.php
@@ -63,9 +63,10 @@ class Cdav {
$sharees = [];
$share_displayname = [];
+
foreach($invites as $invite) {
if(strpos($invite->href, 'mailto:') !== false) {
- $sharee = channelx_by_hash(substr($invite->href, 7));
+ $sharee = channelx_by_nick(substr($invite->principal, 11));
$sharees[] = [
'name' => $sharee['channel_name'],
'access' => (($invite->access == 3) ? ' (RW)' : ' (R)'),
@@ -173,4 +174,4 @@ class Cdav {
}
}
-} \ No newline at end of file
+}
diff --git a/Zotlabs/Widget/Hq_controls.php b/Zotlabs/Widget/Hq_controls.php
new file mode 100644
index 000000000..0caa54a1a
--- /dev/null
+++ b/Zotlabs/Widget/Hq_controls.php
@@ -0,0 +1,26 @@
+<?php
+
+namespace Zotlabs\Widget;
+
+class Hq_controls {
+
+ function widget($arr) {
+
+ if (! local_channel())
+ return;
+
+ return replace_macros(get_markup_template('hq_controls.tpl'),
+ [
+ '$title' => t('HQ Control Panel'),
+ '$menu' => [
+ 'create' => [
+ 'label' => t('Create a new post'),
+ 'id' => 'jot-toggle',
+ 'href' => '#',
+ 'class' => ''
+ ]
+ ]
+ ]
+ );
+ }
+}