From fad381586c2b696e862c63180636a0b24e5e17cc Mon Sep 17 00:00:00 2001 From: Einer von Vielen Date: Thu, 18 Jan 2018 22:39:17 +0100 Subject: How to use CalDAV and CardDAV with Androids DAVDroid --- doc/member/member_guide.bb | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/doc/member/member_guide.bb b/doc/member/member_guide.bb index 20d273f44..6286e74a3 100644 --- a/doc/member/member_guide.bb +++ b/doc/member/member_guide.bb @@ -846,6 +846,23 @@ Your files are visible on the web at the location [observer=1][baseurl]/cloud/[o WebDAV provides a way to copy files directly to or from your computer's operating system, where your cloud files appear as a virtual disk drive. This should be used to upload large files such as video and audio; as it is not limited to available memory. See [zrl=help/member/member_guide#Cloud_Desktop_Clients]Cloud Desktop Clients[/zrl] below. +[h4]CalDAV and CardDAV access on Android[/h4] + +You can sync you calendar and contacts on Android with your Hub. + +The following steps where tested for [url=https://f-droid.org/en/packages/at.bitfire.davdroid/]DAVdroid[/url] +[list] +[*] install DAVdroid +[*] add account +[*] use "URL" and "user name" to login +[list] +[*] base url is [baseurl]/cdav +[*] user name is [observer=1][observer.webname][/observer][observer=0]username[/observer] +[/list] +[/list] + +To share your calendar visit [observer.baseurl]/cdav/calendar + [h4]Permissions[/h4] -- cgit v1.2.3 From 0fba1bb868254c3731d03d9bf5d1b19a8b71b265 Mon Sep 17 00:00:00 2001 From: zotlabs Date: Thu, 18 Jan 2018 14:11:15 -0800 Subject: simplify interactions with the get_features hook by calling it before any filtering takes place --- Zotlabs/Widget/Forums.php | 22 +++++++++++----------- include/features.php | 26 ++++++++++++++------------ 2 files changed, 25 insertions(+), 23 deletions(-) diff --git a/Zotlabs/Widget/Forums.php b/Zotlabs/Widget/Forums.php index 0b90b9740..44d95012f 100644 --- a/Zotlabs/Widget/Forums.php +++ b/Zotlabs/Widget/Forums.php @@ -71,6 +71,8 @@ class Forums { if($r) $r1[$x]['unseen'] = $r[0]['unseen']; + } + /** * @FIXME * This SQL makes the counts correct when you get forum posts arriving from different routes/sources @@ -79,21 +81,19 @@ class Forums { * It may make more sense in that query to look for the mention in the body rather than another join, * but that makes it very inefficient. * - $r = q("select sum(item_unseen) as unseen from item left join term on oid = id where otype = %d and owner_xchan != '%s' and item.uid = %d and url = '%s' and ttype = %d $perms_sql ", - intval(TERM_OBJ_POST), - dbesc($r1[$x]['xchan_hash']), - intval(local_channel()), - dbesc($r1[$x]['xchan_url']), - intval(TERM_MENTION) - ); - if($r) - $r1[$x]['unseen'] = ((array_key_exists('unseen',$r1[$x])) ? $r1[$x]['unseen'] + $r[0]['unseen'] : $r[0]['unseen']); + * $r = q("select sum(item_unseen) as unseen from item left join term on oid = id where otype = %d and owner_xchan != '%s' and item.uid = %d and url = '%s' and ttype = %d $perms_sql ", + * intval(TERM_OBJ_POST), + * dbesc($r1[$x]['xchan_hash']), + * intval(local_channel()), + * dbesc($r1[$x]['xchan_url']), + * intval(TERM_MENTION) + * ); + * if($r) + * $r1[$x]['unseen'] = ((array_key_exists('unseen',$r1[$x])) ? $r1[$x]['unseen'] + $r[0]['unseen'] : $r[0]['unseen']); * * end @FIXME */ - } - if($r1) { $o .= '
'; $o .= '

' . t('Forums') . '

{{/if}} - {{if $qcomment}} - - {{/if}}
-- cgit v1.2.3 From 764d6e3407f75cbe7a6f9635dd40cd2cca0f2b4f Mon Sep 17 00:00:00 2001 From: zotlabs Date: Thu, 18 Jan 2018 17:20:30 -0800 Subject: zot api: provide channel list function (list all channel usernames [e.g. channel_address] associated with the logged in account) --- include/api_zot.php | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/include/api_zot.php b/include/api_zot.php index 54f905b4c..1d30a0845 100644 --- a/include/api_zot.php +++ b/include/api_zot.php @@ -6,6 +6,8 @@ api_register_func('api/export/basic','api_export_basic', true); api_register_func('api/red/channel/export/basic','api_export_basic', true); api_register_func('api/z/1.0/channel/export/basic','api_export_basic', true); + api_register_func('api/red/channel/list','api_channel_list', true); + api_register_func('api/z/1.0/channel/list','api_channel_list', true); api_register_func('api/red/channel/stream','api_channel_stream', true); api_register_func('api/z/1.0/channel/stream','api_channel_stream', true); api_register_func('api/red/files','api_attach_list', true); @@ -111,9 +113,31 @@ } } + function api_channel_list($type) { + if(api_user() === false) { + logger('api_channel_stream: no user'); + return false; + } + + $channel = channelx_by_n(api_user()); + if(! $channel) + return false; + $ret = []; + $r = q("select channel_address from channel where channel_account_id = %d", + intval($channel['channel_account_id']) + ); + + if($r) { + foreach($r as $rv) { + $ret[] = $rv['channel_address']; + } + } + + json_return_and_die($ret); + } function api_channel_stream($type) { -- cgit v1.2.3 From ecd161d678e17c32e74a886ff976da736a512a97 Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Fri, 19 Jan 2018 11:40:16 +0100 Subject: provide a button to clear the name filter --- view/tpl/notifications_widget.tpl | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/view/tpl/notifications_widget.tpl b/view/tpl/notifications_widget.tpl index 9489e850c..c926586eb 100644 --- a/view/tpl/notifications_widget.tpl +++ b/view/tpl/notifications_widget.tpl @@ -65,6 +65,11 @@ $('#nav-{{$notification.type}}-menu [data-thread_top=false]').toggle(); $(this).toggleClass('active sticky-top'); }); + $(document).on('click ', '#cn-{{$notification.type}}-input-clear', function(e) { + $('#cn-{{$notification.type}}-input').val(''); + $('#cn-{{$notification.type}}-only').removeClass('active sticky-top'); + $("#nav-{{$notification.type}}-menu .notification").removeClass('d-none'); + }); $(document).on('keyup', '#cn-{{$notification.type}}-input', function(e) { var val = $('#cn-{{$notification.type}}-input').val().toLowerCase(); @@ -134,8 +139,13 @@
{{$notification.filter.label}}
-
- +
+
+ +
+ +
+
{{/if}}
-
- -
- -
-
+ +
{{/if}}
-
+
{{/if}}