diff options
author | Mario Vavti <mario@mariovavti.com> | 2017-11-19 22:42:16 +0100 |
---|---|---|
committer | Mario Vavti <mario@mariovavti.com> | 2017-11-19 22:42:16 +0100 |
commit | 241a0829dc59c9c4376c10bc2f4ca833510f29eb (patch) | |
tree | db0d0cbbe86dc11963b2de5cab73b42ca732aa51 /Zotlabs/Module/Apporder.php | |
parent | 66a0b4790e97252a93b14c555c5c7fdb6eae5b47 (diff) | |
download | volse-hubzilla-241a0829dc59c9c4376c10bc2f4ca833510f29eb.tar.gz volse-hubzilla-241a0829dc59c9c4376c10bc2f4ca833510f29eb.tar.bz2 volse-hubzilla-241a0829dc59c9c4376c10bc2f4ca833510f29eb.zip |
fix issues with apporder related to recent pinned apps changes
Diffstat (limited to 'Zotlabs/Module/Apporder.php')
-rw-r--r-- | Zotlabs/Module/Apporder.php | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/Zotlabs/Module/Apporder.php b/Zotlabs/Module/Apporder.php index 956548d1f..a9f66ba69 100644 --- a/Zotlabs/Module/Apporder.php +++ b/Zotlabs/Module/Apporder.php @@ -18,7 +18,7 @@ class Apporder extends \Zotlabs\Web\Controller { nav_set_selected('Order Apps'); $syslist = array(); - $list = Zlib\Apps::app_list(local_channel(), false, 'nav_featured_app'); + $list = Zlib\Apps::app_list(local_channel(), false, ['nav_featured_app', 'nav_pinned_app']); if($list) { foreach($list as $li) { $syslist[] = Zlib\Apps::app_encode($li); @@ -31,14 +31,20 @@ class Apporder extends \Zotlabs\Web\Controller { $syslist = Zlib\Apps::app_order(local_channel(),$syslist); foreach($syslist as $app) { - $nav_apps[] = Zlib\Apps::app_render($app,'nav-order'); + if(strpos($app['categories'],'nav_pinned_app') !== false) { + $navbar_apps[] = Zlib\Apps::app_render($app,'nav-order'); + } + else { + $nav_apps[] = Zlib\Apps::app_render($app,'nav-order'); + } } return replace_macros(get_markup_template('apporder.tpl'), [ - '$header' => t('Change Order of Navigation Apps'), - '$desc' => t('Use arrows to move the corresponding app up or down in the display list'), - '$nav_apps' => $nav_apps + '$header' => [t('Change Order of Pinned Navbar Apps'), t('Change Order of App Tray Apps')], + '$desc' => [t('Use arrows to move the corresponding app left (top) or right (bottom) in the navbar'), t('Use arrows to move the corresponding app up or down in the app tray')], + '$nav_apps' => $nav_apps, + '$navbar_apps' => $navbar_apps ] ); } |