fmsystem-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Fmsystem-commits] [11260] api: add rows per page to paging config in ui


From: Sigurd Nes
Subject: [Fmsystem-commits] [11260] api: add rows per page to paging config in uicommon
Date: Sun, 11 Aug 2013 11:36:25 +0000

Revision: 11260
          http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=11260
Author:   sigurdne
Date:     2013-08-11 11:36:24 +0000 (Sun, 11 Aug 2013)
Log Message:
-----------
api: add rows per page to paging config in uicommon

Modified Paths:
--------------
    trunk/phpgwapi/inc/class.uicommon.inc.php

Modified: trunk/phpgwapi/inc/class.uicommon.inc.php
===================================================================
--- trunk/phpgwapi/inc/class.uicommon.inc.php   2013-08-11 08:51:29 UTC (rev 
11259)
+++ trunk/phpgwapi/inc/class.uicommon.inc.php   2013-08-11 11:36:24 UTC (rev 
11260)
@@ -281,6 +281,15 @@
                        $shows_from = lang('shows from');
                        $of_total = lang('of total');
 
+                       if 
(isset($GLOBALS['phpgw_info']['user']['preferences']['common']['maxmatchs']) && 
$GLOBALS['phpgw_info']['user']['preferences']['common']['maxmatchs'] > 0)
+                       {
+                               $rows_per_page = 
$GLOBALS['phpgw_info']['user']['preferences']['common']['maxmatchs'];
+                       }
+                       else
+                       {
+                               $rows_per_page = 10;
+                       }
+
                        $data['yui_phpgw_i18n'] = array(
                                'Calendar' => array(
                                        'WEEKDAYS_SHORT' => 
json_encode($this->lang_array('Su', 'Mo', 'Tu', 'We', 'Th', 'Fr', 'Sa')),
@@ -303,7 +312,8 @@
                                        'firstPageLinkLabel' => 
json_encode("<< {$first}"),
                                        'lastPageLinkLabel' => 
json_encode("{$last} >>"),
                                        'template' => 
json_encode("{CurrentPageReport}<br/>  {FirstPageLink} {PreviousPageLink} 
{PageLinks} {NextPageLink} {LastPageLink}"),
-                                       'pageReportTemplate' => 
json_encode("{$shows_from} {startRecord} {$to} {endRecord} {$of_total} 
{totalRecords}.")
+                                       'pageReportTemplate' => 
json_encode("{$shows_from} {startRecord} {$to} {endRecord} {$of_total} 
{totalRecords}."),
+                                       'rowsPerPage'   => $rows_per_page
                                ),
                                'common' => array(
                                        'LBL_NAME' => json_encode(lang('Name')),




reply via email to

[Prev in Thread] Current Thread [Next in Thread]