diff --git a/bl-kernel/admin/controllers/content.php b/bl-kernel/admin/controllers/content.php index 7e2852a0..7ec0d696 100644 --- a/bl-kernel/admin/controllers/content.php +++ b/bl-kernel/admin/controllers/content.php @@ -35,11 +35,10 @@ function filterContentOwner($list) { // Main after POST // ============================================================================ -$published = $pages->getList($url->pageNumber(), ITEMS_PER_PAGE_ADMIN, ['article'], ['published'], false, false); +$published = $pages->getList($url->pageNumber(), ITEMS_PER_PAGE_ADMIN, ['article'], ['published'], true, true); $drafts = $pages->getDraftDB(['article'], true); $scheduled = $pages->getScheduledDB(['article'],true); $static = $pages->getStaticDB(['published'],true); -$sticky = $pages->getStickyDB(['article'],['published'],true); $autosave = $pages->getAutosaveDB(['article'],true); // If the user is an Author filter the content he/she can edit @@ -48,7 +47,6 @@ if (checkRole(array('author'), false)) { $drafts = filterContentOwner($drafts); $scheduled = filterContentOwner($scheduled); $static = filterContentOwner($static); - $sticky = filterContentOwner($sticky); } // Check if out of range the pageNumber diff --git a/bl-kernel/admin/views/content.php b/bl-kernel/admin/views/content.php index c9247117..18777e11 100644 --- a/bl-kernel/admin/views/content.php +++ b/bl-kernel/admin/views/content.php @@ -9,7 +9,6 @@ function table($type) { global $drafts; global $scheduled; global $static; - global $sticky; global $autosave; if ($type=='published') { @@ -44,14 +43,6 @@ function table($type) { echo '

'; return false; } - } elseif ($type=='sticky') { - $list = $sticky; - if (empty($list)) { - echo '

'; - echo $L->g('There are no sticky pages at this moment.'); - echo '

'; - return false; - } } elseif ($type=='autosave') { $list = $autosave; } @@ -64,7 +55,7 @@ function table($type) { '.$L->g('Title').' '; - if ($type=='published' || $type=='static' || $type=='sticky') { + if ($type=='published' || $type=='static') { echo ''.$L->g('URL').''; } @@ -81,22 +72,27 @@ function table($type) { if (!$page->isChild()) { echo ' -
- ' - .($page->title()?$page->title():''.$L->g('Empty title').' ') - .' -
-
-

'.( ((ORDER_BY=='position') || ($type!='published'))?$L->g('Position').': '.$page->position():$page->date(MANAGE_CONTENT_DATE_FORMAT) ).'

+
' + .($page->sticky()?'
':'') + .'
+
+ ' + .($page->title()?$page->title():''.$L->g('Empty title').' ') + .' +
+
+

'.( ((ORDER_BY=='position') || ($type!='published'))?$L->g('Position').': '.$page->position():$page->date(MANAGE_CONTENT_DATE_FORMAT) ).'

+
+
'; - if ($type=='published' || $type=='static' || $type=='sticky') { + if ($type=='published' || $type=='static') { $friendlyURL = Text::isEmpty($url->filters('page')) ? '/'.$page->key() : '/'.$url->filters('page').'/'.$page->key(); echo ''.$friendlyURL.''; } - echo ''.PHP_EOL; + echo ''.PHP_EOL; echo ''.$L->g('View').''.PHP_EOL; echo ''.$L->g('Edit').''.PHP_EOL; if (count($page->children())==0) { @@ -120,13 +116,13 @@ function table($type) {
'; - if ($type=='published' || $type=='static' || $type=='sticky') { + if ($type=='published' || $type=='static') { $friendlyURL = Text::isEmpty($url->filters('page')) ? '/'.$child->key() : '/'.$url->filters('page').'/'.$child->key(); echo ''.$friendlyURL.''; } - echo ''.PHP_EOL; - if ($type=='published' || $type=='static' || $type=='sticky') { + echo ''.PHP_EOL; + if ($type=='published' || $type=='static') { echo ''.$L->g('View').''.PHP_EOL; } echo ''.$L->g('Edit').''.PHP_EOL; @@ -146,24 +142,28 @@ function table($type) { try { $page = new Page($pageKey); echo ''; - echo ' -
- ' - .($page->title()?$page->title():''.$L->g('Empty title').' ') - .' -
-
-

'.( ($type=='scheduled')?$L->g('Scheduled').': '.$page->date(SCHEDULED_DATE_FORMAT):$page->date(MANAGE_CONTENT_DATE_FORMAT) ).'

-
+ echo ' +
' + .($page->sticky()?'
':'') + .'
+
' + .'' + .($page->title()?$page->title():''.$L->g('Empty title').' ') + .' +
+
+

'.( ($type=='scheduled')?$L->g('Scheduled').': '.$page->date(SCHEDULED_DATE_FORMAT):$page->date(MANAGE_CONTENT_DATE_FORMAT) ).'

+
+
'; - if ($type=='published' || $type=='static' || $type=='sticky') { + if ($type=='published' || $type=='static') { $friendlyURL = Text::isEmpty($url->filters('page')) ? '/'.$page->key() : '/'.$url->filters('page').'/'.$page->key(); - echo ''.$friendlyURL.''; + echo ''.$friendlyURL.''; } - echo ''.PHP_EOL; - if ($type=='published' || $type=='static' || $type=='sticky') { + echo ''.PHP_EOL; + if ($type=='published' || $type=='static') { echo ''.$L->g('View').''.PHP_EOL; } echo ''.$L->g('Edit').''.PHP_EOL; @@ -196,9 +196,6 @@ function table($type) { - @@ -252,11 +249,6 @@ function table($type) {
- -
- -
-