Fixed bug #12273: List view don't show if there are more records than displayed
authorSteffen Kamper <info@sk-typo3.de>
Tue, 20 Oct 2009 16:10:54 +0000 (16:10 +0000)
committerSteffen Kamper <info@sk-typo3.de>
Tue, 20 Oct 2009 16:10:54 +0000 (16:10 +0000)
git-svn-id: https://svn.typo3.org/TYPO3v4/Core/trunk@6187 709f56b5-9817-0410-a4d7-c38de5d9e867

ChangeLog
typo3/class.db_list_extra.inc

index 283e3d1..b60903f 100755 (executable)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,6 @@
 2009-10-20  Steffen Kamper  <info@sk-typo3.de>
 
+       * Fixed bug #12273: List view don't show if there are more records than displayed
        * Follow-up to bug #10467: Added var "showRefreshLoginPopup" to config_default
        * Fixed bug #10467: AJAX relogin does not work
        * Added test #12286: Add unit tests for RemoveXSS
index 6ab6cf4..94502a0 100644 (file)
@@ -566,18 +566,30 @@ class localRecordList extends recordList {
                                        $this->eCounter++;
                                }
 
-                               // Record navigation is added to the beginning and end of the table if in single table mode
+                                       // Record navigation is added to the beginning and end of the table if in single table mode
                                if ($this->table) {
                                        $pageNavigation = $this->renderListNavigation();
                                        $iOut = $pageNavigation . $iOut . $pageNavigation;
+                               } else {
+                                               // show that there are more records than shown
+                                       if ($this->totalItems > $this->itemsLimitPerTable) {
+                                               $countOnFirstPage = $this->totalItems > $this->itemsLimitSingleTable ? $this->itemsLimitSingleTable : $this->totalItems;
+                                               $hasMore = ($this->totalItems > $this->itemsLimitSingleTable);
+                                               $iOut .= '<tr><td colspan="' . count($this->fieldArray) . '" style="padding:5px;">
+                                                               <a href="'.htmlspecialchars($this->listURL() . '&table=' . rawurlencode($table)) . '">' .
+                                                               '<img' . t3lib_iconWorks::skinImg($this->backPath,'gfx/pildown.gif', 'width="14" height="14"') .' alt="" />'.
+                                                               ' <i>[1 - ' . $countOnFirstPage . ($hasMore ? '+' : '') . ']</i></a>
+                                                               </td></tr>';
+                                               }
+
                                }
 
                                        // The header row for the table is now created:
-                               $out.=$this->renderListHeader($table,$currentIdList);
+                               $out .= $this->renderListHeader($table,$currentIdList);
                        }
 
                                // The list of records is added after the header:
-                       $out.=$iOut;
+                       $out .= $iOut;
                        unset($iOut);
 
                                // ... and it is all wrapped in a table: