diff options
author | Mario <mario@mariovavti.com> | 2020-06-11 12:13:44 +0200 |
---|---|---|
committer | Mario <mario@mariovavti.com> | 2020-06-11 12:13:44 +0200 |
commit | c8c4513af98a9dd2a6d9331ba4b3ab3af0e95a5f (patch) | |
tree | 255dc1dbe5745a2bf9b5a4f93ed82628052067cb /Zotlabs | |
parent | 9da8e30c378a58a89d3eeaf2f29d8c8774128235 (diff) | |
parent | 3201a4bec5f3524c2eba813e46d69b4c5943840f (diff) | |
download | volse-hubzilla-c8c4513af98a9dd2a6d9331ba4b3ab3af0e95a5f.tar.gz volse-hubzilla-c8c4513af98a9dd2a6d9331ba4b3ab3af0e95a5f.tar.bz2 volse-hubzilla-c8c4513af98a9dd2a6d9331ba4b3ab3af0e95a5f.zip |
Merge branch 'dev' into 'dev'
allow apps to be both pinned and starred independently
See merge request hubzilla/core!1858
Diffstat (limited to 'Zotlabs')
-rw-r--r-- | Zotlabs/Lib/Apps.php | 6 | ||||
-rw-r--r-- | Zotlabs/Module/Apporder.php | 4 |
2 files changed, 4 insertions, 6 deletions
diff --git a/Zotlabs/Lib/Apps.php b/Zotlabs/Lib/Apps.php index f11bb9628..7b980b8d3 100644 --- a/Zotlabs/Lib/Apps.php +++ b/Zotlabs/Lib/Apps.php @@ -564,7 +564,8 @@ class Apps { '$featured' => ((strpos($papp['categories'], 'nav_featured_app') === false) ? false : true), '$pinned' => ((strpos($papp['categories'], 'nav_pinned_app') === false) ? false : true), '$navapps' => (($mode == 'nav') ? true : false), - '$order' => (($mode == 'nav-order') ? true : false), + '$order' => (($mode === 'nav-order' || $mode === 'nav-order-pinned') ? true : false), + '$mode' => $mode, '$add' => t('Add to app-tray'), '$remove' => t('Remove from app-tray'), '$add_nav' => t('Pin to navbar'), @@ -959,9 +960,6 @@ class Apps { if($list) { foreach($list as $li) { $papp = self::app_encode($li); - if($menu !== 'nav_pinned_app' && strpos($papp['categories'],'nav_pinned_app') !== false) - continue; - $syslist[] = $papp; } } diff --git a/Zotlabs/Module/Apporder.php b/Zotlabs/Module/Apporder.php index eac1abc2d..313c2df50 100644 --- a/Zotlabs/Module/Apporder.php +++ b/Zotlabs/Module/Apporder.php @@ -34,9 +34,9 @@ class Apporder extends \Zotlabs\Web\Controller { foreach($syslist as $app) { if($l === 'nav_pinned_app') { - $navbar_apps[] = Zlib\Apps::app_render($app,'nav-order'); + $navbar_apps[] = Zlib\Apps::app_render($app,'nav-order-pinned'); } - elseif(strpos($app['categories'],'nav_pinned_app') === false) { + else { $nav_apps[] = Zlib\Apps::app_render($app,'nav-order'); } } |