From 4d0611b7d4be21d9b436348fbe9b7b1a4c0b189c Mon Sep 17 00:00:00 2001 From: zotlabs Date: Wed, 1 Aug 2018 16:12:44 -0700 Subject: hubzilla core issue #1258 --- Zotlabs/Widget/Activity_order.php | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Activity_order.php b/Zotlabs/Widget/Activity_order.php index 0e660afc3..27d1a971a 100644 --- a/Zotlabs/Widget/Activity_order.php +++ b/Zotlabs/Widget/Activity_order.php @@ -34,6 +34,7 @@ class Activity_order { break; default: $commentord_active = 'active'; + break; } } else { @@ -78,6 +79,9 @@ class Activity_order { if(x($_GET,'file')) $filter .= '&file=' . $_GET['file']; + if(x($_GET,'pf')) + $filter .= '&pf=' . $_GET['pf']; + // tabs $tabs = []; -- cgit v1.2.3 From f230c07ba5ed71c0491c6fd109c0789d2cc341c1 Mon Sep 17 00:00:00 2001 From: zotlabs Date: Wed, 15 Aug 2018 17:00:37 -0700 Subject: possible fixes for can_comment_on_post(), provide wiki_list on wiki sidebar --- Zotlabs/Widget/Wiki_list.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Wiki_list.php b/Zotlabs/Widget/Wiki_list.php index 62f32dbf0..c8d83cbe8 100644 --- a/Zotlabs/Widget/Wiki_list.php +++ b/Zotlabs/Widget/Wiki_list.php @@ -6,13 +6,17 @@ class Wiki_list { function widget($arr) { + if(argc() < 3) { + return; + } + $channel = channelx_by_n(\App::$profile_uid); $wikis = \Zotlabs\Lib\NativeWiki::listwikis($channel,get_observer_hash()); if($wikis) { return replace_macros(get_markup_template('wikilist_widget.tpl'), array( - '$header' => t('Wiki List'), + '$header' => t('Wikis'), '$channel' => $channel['channel_address'], '$wikis' => $wikis['wikis'] )); -- cgit v1.2.3 From a9bbfe9c4f0b783433ceb6c586022093e74aa718 Mon Sep 17 00:00:00 2001 From: zotlabs Date: Mon, 20 Aug 2018 17:38:38 -0700 Subject: Only show cover photos once per login session. After that they can get annoying. If there is pushback on this, then it should perhaps be optional. --- Zotlabs/Widget/Cover_photo.php | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Cover_photo.php b/Zotlabs/Widget/Cover_photo.php index d2eb1be92..af1ae5c7f 100644 --- a/Zotlabs/Widget/Cover_photo.php +++ b/Zotlabs/Widget/Cover_photo.php @@ -20,6 +20,16 @@ class Cover_photo { if(! $channel_id) return ''; + // only show cover photos once per login session + + if(array_key_exists('channels_visited',$_SESSION) && is_array($_SESSION['channels_visited']) && in_array($channel_id,$_SESSION['channels_visited'])) { + return EMPTY_STR; + } + if(! array_key_exists('channels_visited',$_SESSION)) { + $_SESSION['channels_visited'] = []; + } + $_SESSION['channels_visited'][] = $channel_id; + $channel = channelx_by_n($channel_id); if(array_key_exists('style', $arr) && isset($arr['style'])) -- cgit v1.2.3 From 6ecd31a715c3d4fb5f2073f376cb9509bc6427d6 Mon Sep 17 00:00:00 2001 From: zotlabs Date: Wed, 22 Aug 2018 13:30:16 -0700 Subject: tweak archive widget for articles --- Zotlabs/Widget/Archive.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Archive.php b/Zotlabs/Widget/Archive.php index c151ca563..9adaac38f 100644 --- a/Zotlabs/Widget/Archive.php +++ b/Zotlabs/Widget/Archive.php @@ -22,12 +22,12 @@ class Archive { return ''; $wall = ((array_key_exists('wall', $arr)) ? intval($arr['wall']) : 0); + $wall = ((array_key_exists('articles', $arr)) ? 2 : $wall); + $style = ((array_key_exists('style', $arr)) ? $arr['style'] : 'select'); $showend = ((get_pconfig($uid,'system','archive_show_end_date')) ? true : false); $mindate = get_pconfig($uid,'system','archive_mindate'); - $visible_years = get_pconfig($uid,'system','archive_visible_years'); - if(! $visible_years) - $visible_years = 5; + $visible_years = get_pconfig($uid,'system','archive_visible_years',5); $url = z_root() . '/' . \App::$cmd; -- cgit v1.2.3 From 88ebcb56e7d1f70a594f3f11b0d209e084a3521a Mon Sep 17 00:00:00 2001 From: Max Kostikov Date: Sat, 25 Aug 2018 21:23:08 +0200 Subject: Update Wiki_page_history.php --- Zotlabs/Widget/Wiki_page_history.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Wiki_page_history.php b/Zotlabs/Widget/Wiki_page_history.php index dcec9a037..0f865f12d 100644 --- a/Zotlabs/Widget/Wiki_page_history.php +++ b/Zotlabs/Widget/Wiki_page_history.php @@ -20,7 +20,10 @@ class Wiki_page_history { '$pageHistory' => $pageHistory['history'], '$permsWrite' => $arr['permsWrite'], '$name_lbl' => t('Name'), - '$msg_label' => t('Message','wiki_history') + '$msg_label' => t('Message','wiki_history'), + '$date_lbl' => t('Date'), + '$revert_btn' => t('Revert'), + '$compare_btn' => t('Compare') )); } -- cgit v1.2.3 From 42c5e986707ffaa660b4fda9f23edbae9a3cb639 Mon Sep 17 00:00:00 2001 From: Max Kostikov Date: Sat, 25 Aug 2018 21:27:20 +0200 Subject: Update Wiki_page_history.php --- Zotlabs/Widget/Wiki_page_history.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Wiki_page_history.php b/Zotlabs/Widget/Wiki_page_history.php index 0f865f12d..dbb322dc3 100644 --- a/Zotlabs/Widget/Wiki_page_history.php +++ b/Zotlabs/Widget/Wiki_page_history.php @@ -21,9 +21,9 @@ class Wiki_page_history { '$permsWrite' => $arr['permsWrite'], '$name_lbl' => t('Name'), '$msg_label' => t('Message','wiki_history'), - '$date_lbl' => t('Date'), - '$revert_btn' => t('Revert'), - '$compare_btn' => t('Compare') + '$date_lbl' => t('Date'), + '$revert_btn' => t('Revert'), + '$compare_btn' => t('Compare') )); } -- cgit v1.2.3 From a821682c8c165077947781bca2064922884f6e7d Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Wed, 5 Sep 2018 12:17:32 +0200 Subject: instead of not displaying the cover-photo at all after first page load, load the page with the cover slided up. change pointer to n-resize if cover is not slid. --- Zotlabs/Widget/Cover_photo.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Cover_photo.php b/Zotlabs/Widget/Cover_photo.php index af1ae5c7f..965566523 100644 --- a/Zotlabs/Widget/Cover_photo.php +++ b/Zotlabs/Widget/Cover_photo.php @@ -21,9 +21,9 @@ class Cover_photo { return ''; // only show cover photos once per login session - + $hide_cover = false; if(array_key_exists('channels_visited',$_SESSION) && is_array($_SESSION['channels_visited']) && in_array($channel_id,$_SESSION['channels_visited'])) { - return EMPTY_STR; + $hide_cover = true; } if(! array_key_exists('channels_visited',$_SESSION)) { $_SESSION['channels_visited'] = []; @@ -53,6 +53,7 @@ class Cover_photo { $subtitle = str_replace('@','@',$channel['xchan_addr']); $c = get_cover_photo($channel_id,'html'); + $c = str_replace('src=', 'data-src=', $c); if($c) { $photo_html = (($style) ? str_replace('alt=',' style="' . $style . '" alt=',$c) : $c); @@ -62,6 +63,7 @@ class Cover_photo { '$title' => $title, '$subtitle' => $subtitle, '$hovertitle' => t('Click to show more'), + '$hide_cover' => $hide_cover )); } return $o; -- cgit v1.2.3 From ea381d918021a33a73df40de95fd0c57f0edc5c2 Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Wed, 5 Sep 2018 14:44:06 +0200 Subject: move str_replace inside if clause --- Zotlabs/Widget/Cover_photo.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Cover_photo.php b/Zotlabs/Widget/Cover_photo.php index 965566523..955048992 100644 --- a/Zotlabs/Widget/Cover_photo.php +++ b/Zotlabs/Widget/Cover_photo.php @@ -53,9 +53,9 @@ class Cover_photo { $subtitle = str_replace('@','@',$channel['xchan_addr']); $c = get_cover_photo($channel_id,'html'); - $c = str_replace('src=', 'data-src=', $c); if($c) { + $c = str_replace('src=', 'data-src=', $c); $photo_html = (($style) ? str_replace('alt=',' style="' . $style . '" alt=',$c) : $c); $o = replace_macros(get_markup_template('cover_photo_widget.tpl'),array( -- cgit v1.2.3 From c6abe87ec2e08fc38ff9c505ac2000d52d45c228 Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Mon, 10 Sep 2018 13:34:05 +0200 Subject: move cards from features to apps --- Zotlabs/Widget/Categories.php | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Categories.php b/Zotlabs/Widget/Categories.php index 9bfa9742a..27d4b5980 100644 --- a/Zotlabs/Widget/Categories.php +++ b/Zotlabs/Widget/Categories.php @@ -2,6 +2,9 @@ namespace Zotlabs\Widget; +use App; +use Zotlabs\Lib\Apps; + require_once('include/contact_widgets.php'); class Categories { @@ -10,22 +13,22 @@ class Categories { $cards = ((array_key_exists('cards',$arr) && $arr['cards']) ? true : false); - if(($cards) && (! feature_enabled(\App::$profile['profile_uid'],'cards'))) + if(($cards) && (! Apps::system_app_installed(App::$profile['profile_uid'], 'Cards'))) return ''; $articles = ((array_key_exists('articles',$arr) && $arr['articles']) ? true : false); - if(($articles) && (! feature_enabled(\App::$profile['profile_uid'],'articles'))) + if(($articles) && (! feature_enabled(App::$profile['profile_uid'],'articles'))) return ''; - if((! \App::$profile['profile_uid']) - || (! perm_is_allowed(\App::$profile['profile_uid'],get_observer_hash(),(($cards || $articles) ? 'view_pages' : 'view_stream')))) { + if((! App::$profile['profile_uid']) + || (! perm_is_allowed(App::$profile['profile_uid'],get_observer_hash(),(($cards || $articles) ? 'view_pages' : 'view_stream')))) { return ''; } $cat = ((x($_REQUEST,'cat')) ? htmlspecialchars($_REQUEST['cat'],ENT_COMPAT,'UTF-8') : ''); - $srchurl = (($cards) ? \App::$argv[0] . '/' . \App::$argv[1] : \App::$query_string); + $srchurl = (($cards) ? App::$argv[0] . '/' . App::$argv[1] : App::$query_string); $srchurl = rtrim(preg_replace('/cat\=[^\&].*?(\&|$)/is','',$srchurl),'&'); $srchurl = str_replace(array('?f=','&f='),array('',''),$srchurl); -- cgit v1.2.3 From 2651eae663869e78aa0166bd33ac80a44b26b5ea Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Wed, 12 Sep 2018 11:08:53 +0200 Subject: mpre feature to app transition --- Zotlabs/Widget/Appstore.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Appstore.php b/Zotlabs/Widget/Appstore.php index 237707733..6a00ac06a 100644 --- a/Zotlabs/Widget/Appstore.php +++ b/Zotlabs/Widget/Appstore.php @@ -10,9 +10,9 @@ class Appstore { return replace_macros(get_markup_template('appstore.tpl'), [ '$title' => t('App Collections'), '$options' => [ - [ z_root() . '/apps/available', t('Available Apps'), $store ], - [ z_root() . '/apps', t('Installed apps'), 1 - $store ] + [ z_root() . '/apps', t('Installed apps'), 1 - $store ], + [ z_root() . '/apps/available', t('Available Apps'), $store ] ] ]); } -} \ No newline at end of file +} -- cgit v1.2.3 From 869534fafa543a76e58c32d5aa8f674217682162 Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Thu, 13 Sep 2018 11:53:59 +0200 Subject: remove network_tabs() which has been deprecated and replaced by activity_{order, filters} widgets --- Zotlabs/Widget/Activity_filter.php | 2 +- Zotlabs/Widget/Activity_order.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Activity_filter.php b/Zotlabs/Widget/Activity_filter.php index fadf39144..d725f8b55 100644 --- a/Zotlabs/Widget/Activity_filter.php +++ b/Zotlabs/Widget/Activity_filter.php @@ -180,7 +180,7 @@ class Activity_filter { $arr = ['tabs' => $tabs]; - call_hooks('network_tabs', $arr); + call_hooks('activity_filter', $arr); $o = ''; diff --git a/Zotlabs/Widget/Activity_order.php b/Zotlabs/Widget/Activity_order.php index 27d1a971a..2dceee70e 100644 --- a/Zotlabs/Widget/Activity_order.php +++ b/Zotlabs/Widget/Activity_order.php @@ -110,7 +110,7 @@ class Activity_order { $arr = ['tabs' => $tabs]; - call_hooks('network_tabs', $arr); + call_hooks('activity_order', $arr); $o = ''; -- cgit v1.2.3 From c3aa15cc165730b6e67de580065ace255454dfb5 Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Mon, 24 Sep 2018 11:46:18 +0200 Subject: appification of notes --- Zotlabs/Widget/Notes.php | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Notes.php b/Zotlabs/Widget/Notes.php index 5c83a550f..238008d81 100644 --- a/Zotlabs/Widget/Notes.php +++ b/Zotlabs/Widget/Notes.php @@ -2,20 +2,26 @@ namespace Zotlabs\Widget; +use Zotlabs\Lib\Apps; + class Notes { function widget($arr) { if(! local_channel()) - return ''; - if(! feature_enabled(local_channel(),'private_notes')) - return ''; + return EMPTY_STR; + + if(! Apps::system_app_installed(local_channel(), 'Notes')) + return EMPTY_STR; $text = get_pconfig(local_channel(),'notes','text'); - $o = replace_macros(get_markup_template('notes.tpl'), array( + $tpl = get_markup_template('notes.tpl'); + + $o = replace_macros($tpl, array( '$banner' => t('Notes'), '$text' => $text, '$save' => t('Save'), + '$app' => ((isset($arr['app'])) ? true : false) )); return $o; -- cgit v1.2.3 From 4c58a5cef278357c1bc31b76cfbd2719e3338398 Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Tue, 25 Sep 2018 10:06:24 +0200 Subject: premium channel app --- Zotlabs/Widget/Settings_menu.php | 19 +------------------ 1 file changed, 1 insertion(+), 18 deletions(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Settings_menu.php b/Zotlabs/Widget/Settings_menu.php index f35d6f147..1b96e4d14 100644 --- a/Zotlabs/Widget/Settings_menu.php +++ b/Zotlabs/Widget/Settings_menu.php @@ -111,7 +111,6 @@ class Settings_menu { ); } - if($role === false || $role === 'custom') { $tabs[] = array( 'label' => t('Connection Default Permissions'), @@ -120,22 +119,6 @@ class Settings_menu { ); } - if(feature_enabled(local_channel(),'premium_channel')) { - $tabs[] = array( - 'label' => t('Premium Channel Settings'), - 'url' => z_root() . '/connect/' . $channel['channel_address'], - 'selected' => '' - ); - } - - if(feature_enabled(local_channel(),'channel_sources')) { - $tabs[] = array( - 'label' => t('Channel Sources'), - 'url' => z_root() . '/sources', - 'selected' => '' - ); - } - $tabtpl = get_markup_template("generic_links_widget.tpl"); return replace_macros($tabtpl, array( '$title' => t('Settings'), @@ -144,4 +127,4 @@ class Settings_menu { )); } -} \ No newline at end of file +} -- cgit v1.2.3 From 39866b74637a58df5b1ffb8f2b6f164849d65315 Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Tue, 25 Sep 2018 11:37:22 +0200 Subject: move start_menu switch to settings/display for now --- Zotlabs/Widget/Newmember.php | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Newmember.php b/Zotlabs/Widget/Newmember.php index 1a4b575b9..e57cf5171 100644 --- a/Zotlabs/Widget/Newmember.php +++ b/Zotlabs/Widget/Newmember.php @@ -17,7 +17,14 @@ class Newmember { if(! $a) return EMPTY_STR; - if(! feature_enabled(local_channel(),'start_menu')) + if($a['account_created'] > datetime_convert('','','now - 60 days')) { + $enabled = get_pconfig(local_channel(), 'system', 'start_menu', 1); + } + else { + $enabled = get_pconfig(local_channel(), 'system', 'start_menu', 0); + } + + if(! $enabled) return EMPTY_STR; $options = [ -- cgit v1.2.3 From 9948bb3f2aa3bf3efa68623b87ba854fb59b4926 Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Tue, 25 Sep 2018 12:59:53 +0200 Subject: appification of privacy groups --- Zotlabs/Widget/Activity_filter.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Activity_filter.php b/Zotlabs/Widget/Activity_filter.php index d725f8b55..912bfce49 100644 --- a/Zotlabs/Widget/Activity_filter.php +++ b/Zotlabs/Widget/Activity_filter.php @@ -2,6 +2,8 @@ namespace Zotlabs\Widget; +use Zotlabs\Lib\Apps; + class Activity_filter { function widget($arr) { @@ -44,7 +46,7 @@ class Activity_filter { ]; } - if(feature_enabled(local_channel(),'groups')) { + if(Apps::system_app_installed(local_channel(), 'Privacy Groups')) { $groups = q("SELECT * FROM groups WHERE deleted = 0 AND uid = %d ORDER BY gname ASC", intval(local_channel()) ); -- cgit v1.2.3 From 505782f224d232acd57f7a5986adfc9bf8a7bb79 Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Wed, 26 Sep 2018 16:35:05 +0200 Subject: remove oauth from features --- Zotlabs/Widget/Settings_menu.php | 16 ---------------- 1 file changed, 16 deletions(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Settings_menu.php b/Zotlabs/Widget/Settings_menu.php index 1b96e4d14..041ca312f 100644 --- a/Zotlabs/Widget/Settings_menu.php +++ b/Zotlabs/Widget/Settings_menu.php @@ -79,22 +79,6 @@ class Settings_menu { 'selected' => '' ); - if(feature_enabled(local_channel(),'oauth_clients')) { - $tabs[] = array( - 'label' => t('OAuth1 apps'), - 'url' => z_root() . '/settings/oauth', - 'selected' => ((argv(1) === 'oauth') ? 'active' : ''), - ); - } - - if(feature_enabled(local_channel(),'oauth2_clients')) { - $tabs[] = array( - 'label' => t('OAuth2 apps'), - 'url' => z_root() . '/settings/oauth2', - 'selected' => ((argv(1) === 'oauth2') ? 'active' : ''), - ); - } - if(feature_enabled(local_channel(),'access_tokens')) { $tabs[] = array( 'label' => t('Guest Access Tokens'), -- cgit v1.2.3 From a7948d7bfee1c0c8c9f1a731aabdc636c280bff0 Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Wed, 26 Sep 2018 22:02:50 +0200 Subject: permcats app --- Zotlabs/Widget/Settings_menu.php | 8 -------- 1 file changed, 8 deletions(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Settings_menu.php b/Zotlabs/Widget/Settings_menu.php index 041ca312f..781f3b145 100644 --- a/Zotlabs/Widget/Settings_menu.php +++ b/Zotlabs/Widget/Settings_menu.php @@ -87,14 +87,6 @@ class Settings_menu { ); } - if(feature_enabled(local_channel(),'permcats')) { - $tabs[] = array( - 'label' => t('Permission Categories'), - 'url' => z_root() . '/settings/permcats', - 'selected' => ((argv(1) === 'permcats') ? 'active' : ''), - ); - } - if($role === false || $role === 'custom') { $tabs[] = array( 'label' => t('Connection Default Permissions'), -- cgit v1.2.3 From e3c04b1fd0f441e0042e218f47696b1bfad26c73 Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Wed, 26 Sep 2018 22:24:36 +0200 Subject: guest access app --- Zotlabs/Widget/Settings_menu.php | 8 -------- 1 file changed, 8 deletions(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Settings_menu.php b/Zotlabs/Widget/Settings_menu.php index 781f3b145..ecf93ec78 100644 --- a/Zotlabs/Widget/Settings_menu.php +++ b/Zotlabs/Widget/Settings_menu.php @@ -79,14 +79,6 @@ class Settings_menu { 'selected' => '' ); - if(feature_enabled(local_channel(),'access_tokens')) { - $tabs[] = array( - 'label' => t('Guest Access Tokens'), - 'url' => z_root() . '/settings/tokens', - 'selected' => ((argv(1) === 'tokens') ? 'active' : ''), - ); - } - if($role === false || $role === 'custom') { $tabs[] = array( 'label' => t('Connection Default Permissions'), -- cgit v1.2.3 From 6b23c3e1796b818ce893ed919f2e2bdd000c83fb Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Thu, 27 Sep 2018 14:56:47 +0200 Subject: implement conversation tools (settings/conversation), remove additional features from the settings menu and get rid of skill levels --- Zotlabs/Widget/Settings_menu.php | 8 -------- 1 file changed, 8 deletions(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Settings_menu.php b/Zotlabs/Widget/Settings_menu.php index ecf93ec78..92f615452 100644 --- a/Zotlabs/Widget/Settings_menu.php +++ b/Zotlabs/Widget/Settings_menu.php @@ -45,14 +45,6 @@ class Settings_menu { ); - if(get_account_techlevel() > 0 && get_features()) { - $tabs[] = array( - 'label' => t('Additional features'), - 'url' => z_root().'/settings/features', - 'selected' => ((argv(1) === 'features') ? 'active' : ''), - ); - } - $tabs[] = array( 'label' => t('Addon settings'), 'url' => z_root().'/settings/featured', -- cgit v1.2.3 From 80b47734a7a89f4889e8b9fc8e8879efa5f8431d Mon Sep 17 00:00:00 2001 From: Max Kostikov Date: Fri, 28 Sep 2018 00:01:39 +0200 Subject: Update Activity_filter.php --- Zotlabs/Widget/Activity_filter.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Activity_filter.php b/Zotlabs/Widget/Activity_filter.php index 912bfce49..c27a5d48b 100644 --- a/Zotlabs/Widget/Activity_filter.php +++ b/Zotlabs/Widget/Activity_filter.php @@ -47,7 +47,7 @@ class Activity_filter { } if(Apps::system_app_installed(local_channel(), 'Privacy Groups')) { - $groups = q("SELECT * FROM groups WHERE deleted = 0 AND uid = %d ORDER BY gname ASC", + $groups = q("SELECT * FROM pgrp WHERE deleted = 0 AND uid = %d ORDER BY gname ASC", intval(local_channel()) ); -- cgit v1.2.3 From d7a20821c3b5920715384e1256315fdddd4ba96b Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Fri, 28 Sep 2018 11:32:00 +0200 Subject: move display settings up --- Zotlabs/Widget/Settings_menu.php | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Settings_menu.php b/Zotlabs/Widget/Settings_menu.php index 92f615452..238b8071e 100644 --- a/Zotlabs/Widget/Settings_menu.php +++ b/Zotlabs/Widget/Settings_menu.php @@ -45,11 +45,6 @@ class Settings_menu { ); - $tabs[] = array( - 'label' => t('Addon settings'), - 'url' => z_root().'/settings/featured', - 'selected' => ((argv(1) === 'featured') ? 'active' : ''), - ); $tabs[] = array( 'label' => t('Display settings'), @@ -57,6 +52,12 @@ class Settings_menu { 'selected' => ((argv(1) === 'display') ? 'active' : ''), ); + $tabs[] = array( + 'label' => t('Addon settings'), + 'url' => z_root().'/settings/featured', + 'selected' => ((argv(1) === 'featured') ? 'active' : ''), + ); + if($hublocs) { $tabs[] = array( 'label' => t('Manage locations'), -- cgit v1.2.3 From cc9ca8bbffaceb7273b4999e538a3d211ae3cf09 Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Sat, 29 Sep 2018 18:38:19 +0200 Subject: do not unset $_GET[search] and adjust activity_order widget --- Zotlabs/Widget/Activity_order.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Activity_order.php b/Zotlabs/Widget/Activity_order.php index 2dceee70e..d9dbcc91f 100644 --- a/Zotlabs/Widget/Activity_order.php +++ b/Zotlabs/Widget/Activity_order.php @@ -55,7 +55,7 @@ class Activity_order { } // override order for search, filer and cid results - if(x($_GET,'search') || x($_GET,'file') || (! x($_GET,'pf') && x($_GET,'cid'))) { + if(x($_GET,'search') || x($_GET,'file') || (! x($_GET,'pf') && x($_GET,'cid')) || x($_GET,'verb') || x($_GET,'tag') || x($_GET,'cat')) { $unthreaded_active = 'active'; $commentord_active = $postord_active = 'disabled'; } -- cgit v1.2.3 From 72abe5f3d377043f6aba31090a6671a7e171ddfb Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Mon, 1 Oct 2018 12:47:14 +0200 Subject: do not rely on startpage pconfig anymore --- Zotlabs/Widget/Notifications.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Notifications.php b/Zotlabs/Widget/Notifications.php index a4cf4e706..0f9f609e4 100644 --- a/Zotlabs/Widget/Notifications.php +++ b/Zotlabs/Widget/Notifications.php @@ -160,7 +160,7 @@ class Notifications { '$notifications' => $notifications, '$no_notifications' => t('Sorry, you have got no notifications at the moment'), '$loading' => t('Loading'), - '$startpage' => get_pconfig(local_channel(), 'system', 'startpage') + '$startpage' => $channel['channel_startpage'] )); return $o; -- cgit v1.2.3 From d0605e8d5f7c666fffc01352de4d9ed4738f41ab Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Thu, 4 Oct 2018 11:50:38 +0200 Subject: uexport app --- Zotlabs/Widget/Settings_menu.php | 7 ------- 1 file changed, 7 deletions(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Settings_menu.php b/Zotlabs/Widget/Settings_menu.php index 238b8071e..194c4b05b 100644 --- a/Zotlabs/Widget/Settings_menu.php +++ b/Zotlabs/Widget/Settings_menu.php @@ -9,7 +9,6 @@ class Settings_menu { if(! local_channel()) return; - $channel = \App::get_channel(); $abook_self_id = 0; @@ -66,12 +65,6 @@ class Settings_menu { ); } - $tabs[] = array( - 'label' => t('Export channel'), - 'url' => z_root() . '/uexport', - 'selected' => '' - ); - if($role === false || $role === 'custom') { $tabs[] = array( 'label' => t('Connection Default Permissions'), -- cgit v1.2.3 From c00dc6120d5a458a2386ab4e561437d9f8c62b3c Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Thu, 4 Oct 2018 13:26:45 +0200 Subject: defperm app --- Zotlabs/Widget/Settings_menu.php | 8 -------- 1 file changed, 8 deletions(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Settings_menu.php b/Zotlabs/Widget/Settings_menu.php index 194c4b05b..a4b288441 100644 --- a/Zotlabs/Widget/Settings_menu.php +++ b/Zotlabs/Widget/Settings_menu.php @@ -65,14 +65,6 @@ class Settings_menu { ); } - if($role === false || $role === 'custom') { - $tabs[] = array( - 'label' => t('Connection Default Permissions'), - 'url' => z_root() . '/defperms', - 'selected' => '' - ); - } - $tabtpl = get_markup_template("generic_links_widget.tpl"); return replace_macros($tabtpl, array( '$title' => t('Settings'), -- cgit v1.2.3 From cccea911fa6a8dadb8fae03676ac933b2ed9592a Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Thu, 4 Oct 2018 13:44:26 +0200 Subject: remove redundant var --- Zotlabs/Widget/Settings_menu.php | 2 -- 1 file changed, 2 deletions(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Settings_menu.php b/Zotlabs/Widget/Settings_menu.php index a4b288441..c537c3835 100644 --- a/Zotlabs/Widget/Settings_menu.php +++ b/Zotlabs/Widget/Settings_menu.php @@ -15,8 +15,6 @@ class Settings_menu { // Retrieve the 'self' address book entry for use in the auto-permissions link - $role = get_pconfig(local_channel(),'system','permissions_role'); - $abk = q("select abook_id from abook where abook_channel = %d and abook_self = 1 limit 1", intval(local_channel()) ); -- cgit v1.2.3 From d1a3561585f5bedc8c5d093d7ab09c719a205553 Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Sat, 6 Oct 2018 14:52:42 +0000 Subject: rename widget titles (cherry picked from commit da8b276699b7d4081125456946c2d3b6af330381) --- Zotlabs/Widget/Activity_filter.php | 2 +- Zotlabs/Widget/Activity_order.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Activity_filter.php b/Zotlabs/Widget/Activity_filter.php index c27a5d48b..4ea0086dd 100644 --- a/Zotlabs/Widget/Activity_filter.php +++ b/Zotlabs/Widget/Activity_filter.php @@ -192,7 +192,7 @@ class Activity_filter { ]); $o .= replace_macros(get_markup_template('activity_filter_widget.tpl'), [ - '$title' => t('Activity Filters'), + '$title' => t('Stream Filters'), '$reset' => $reset, '$content' => $content, '$name' => $name diff --git a/Zotlabs/Widget/Activity_order.php b/Zotlabs/Widget/Activity_order.php index d9dbcc91f..1cba1ce8c 100644 --- a/Zotlabs/Widget/Activity_order.php +++ b/Zotlabs/Widget/Activity_order.php @@ -120,7 +120,7 @@ class Activity_order { ]); $o = replace_macros(get_markup_template('common_widget.tpl'), [ - '$title' => t('Activity Order'), + '$title' => t('Stream Order'), '$content' => $content, ]); } -- cgit v1.2.3 From bf878dc4461ea28f71055d59496b21a1685ef63e Mon Sep 17 00:00:00 2001 From: "M.Dent" Date: Sun, 7 Oct 2018 23:08:47 +0000 Subject: Implement custom escaping (cherry picked from commit 93a310582f044d35f0a3583671053595fefdbedb) --- Zotlabs/Widget/Wiki_pages.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Wiki_pages.php b/Zotlabs/Widget/Wiki_pages.php index ecd2c9100..831662ca9 100644 --- a/Zotlabs/Widget/Wiki_pages.php +++ b/Zotlabs/Widget/Wiki_pages.php @@ -2,6 +2,7 @@ namespace Zotlabs\Widget; +use Zotlabs\Lib\NativeWiki; class Wiki_pages { @@ -21,7 +22,7 @@ class Wiki_pages { $can_create = perm_is_allowed(\App::$profile['uid'],get_observer_hash(),'write_wiki'); $can_delete = ((local_channel() && (local_channel() == \App::$profile['uid'])) ? true : false); - $pageName = addslashes(escape_tags(urldecode(argv(3)))); + $pageName = NativeWiki::name_decode(escape_tags(argv(3))); return replace_macros(get_markup_template('wiki_page_not_found.tpl'), array( '$resource_id' => $arr['resource_id'], -- cgit v1.2.3 From d8f79f48e9b4859383eaeea35da6d32045f55ae1 Mon Sep 17 00:00:00 2001 From: "M.Dent" Date: Mon, 8 Oct 2018 17:22:39 +0000 Subject: Rework Wiki encoding scheme. (cherry picked from commit 709665846e66f093109730691b31d9e094d02088) --- Zotlabs/Widget/Wiki_pages.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Wiki_pages.php b/Zotlabs/Widget/Wiki_pages.php index 831662ca9..dee0a2229 100644 --- a/Zotlabs/Widget/Wiki_pages.php +++ b/Zotlabs/Widget/Wiki_pages.php @@ -11,7 +11,7 @@ class Wiki_pages { return; $c = channelx_by_nick(argv(1)); - $w = \Zotlabs\Lib\NativeWiki::exists_by_name($c['channel_id'],urldecode(argv(2))); + $w = \Zotlabs\Lib\NativeWiki::exists_by_name($c['channel_id'],NativeWiki::name_decode(argv(2))); $arr = array( 'resource_id' => $w['resource_id'], 'channel_id' => $c['channel_id'], @@ -24,6 +24,7 @@ class Wiki_pages { $can_delete = ((local_channel() && (local_channel() == \App::$profile['uid'])) ? true : false); $pageName = NativeWiki::name_decode(escape_tags(argv(3))); + $wikiname = $w['urlName']; return replace_macros(get_markup_template('wiki_page_not_found.tpl'), array( '$resource_id' => $arr['resource_id'], '$channel_address' => $arr['channel_address'], @@ -49,7 +50,7 @@ class Wiki_pages { if(! $arr['resource_id']) { $c = channelx_by_nick(argv(1)); - $w = \Zotlabs\Lib\NativeWiki::exists_by_name($c['channel_id'],urldecode(argv(2))); + $w = \Zotlabs\Lib\NativeWiki::exists_by_name($c['channel_id'],NativeWiki::name_decode(argv(2))); $arr = array( 'resource_id' => $w['resource_id'], 'channel_id' => $c['channel_id'], -- cgit v1.2.3 From 34b4b658658fe6aefbc13da5d03262eb16b2443f Mon Sep 17 00:00:00 2001 From: Mario Vavti Date: Mon, 15 Oct 2018 18:18:25 +0000 Subject: add missing features section to newmember widget (cherry picked from commit 25a74f366460144d12287b51bdbdb48ebcadfb98) --- Zotlabs/Widget/Newmember.php | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'Zotlabs/Widget') diff --git a/Zotlabs/Widget/Newmember.php b/Zotlabs/Widget/Newmember.php index e57cf5171..224f7a8a2 100644 --- a/Zotlabs/Widget/Newmember.php +++ b/Zotlabs/Widget/Newmember.php @@ -51,7 +51,13 @@ class Newmember { t('Miscellaneous'), [ 'settings' => t('Settings'), - 'help' => t('Documentation'), + 'help' => t('Documentation'), + ], + + t('Missing Features?'), + [ + 'apps' => t('Pin apps to navigation bar'), + 'apps/available' => t('Install more apps') ] ]; -- cgit v1.2.3