[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Fmsystem-commits] [14808] translations and allrows for inline tables
From: |
Sigurd Nes |
Subject: |
[Fmsystem-commits] [14808] translations and allrows for inline tables |
Date: |
Fri, 04 Mar 2016 10:14:46 +0000 |
Revision: 14808
http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=14808
Author: sigurdne
Date: 2016-03-04 10:14:46 +0000 (Fri, 04 Mar 2016)
Log Message:
-----------
translations and allrows for inline tables
Modified Paths:
--------------
trunk/phpgwapi/inc/class.uicommon_jquery.inc.php
trunk/phpgwapi/js/jquery/common.js
trunk/phpgwapi/templates/base/datatable_inline.xsl
trunk/property/inc/class.uicondition_survey.inc.php
Modified: trunk/phpgwapi/inc/class.uicommon_jquery.inc.php
===================================================================
--- trunk/phpgwapi/inc/class.uicommon_jquery.inc.php 2016-03-04 09:55:24 UTC
(rev 14807)
+++ trunk/phpgwapi/inc/class.uicommon_jquery.inc.php 2016-03-04 10:14:46 UTC
(rev 14808)
@@ -361,7 +361,8 @@
'sortDescending' => $sort_desc
)),
),
- 'lengthmenu' => array('_' =>
json_encode($lengthmenu))
+ 'lengthmenu' => array('_' =>
json_encode($lengthmenu)),
+ 'lengthmenu_allrows' => array('_' =>
json_encode(array(-1, lang('all'))))
);
// _debug_array($data['jquery_phpgw_i18n']);die();
}
Modified: trunk/phpgwapi/js/jquery/common.js
===================================================================
--- trunk/phpgwapi/js/jquery/common.js 2016-03-04 09:55:24 UTC (rev 14807)
+++ trunk/phpgwapi/js/jquery/common.js 2016-03-04 10:14:46 UTC (rev 14808)
@@ -247,6 +247,7 @@
var initial_search = options['initial_search'] || false;
var editor_action = options['editor_action'] || false;
var editor_cols = [];
+ var allrows = options['allrows'] || false;
for (i = 0; i < columns.length; i++)
{
@@ -270,6 +271,34 @@
lengthMenu = [10, 25, 50, 100];
}
+ if (allrows == true)
+ {
+ lengthmenu_allrows = [];
+
+ try
+ {
+ lengthmenu_allrows =
JqueryPortico.i18n.lengthmenu_allrows();
+
+ if (lengthMenu.length == 2)
+ {
+ lengthMenu[0].push(lengthmenu_allrows[0]);
+ lengthMenu[1].push(lengthmenu_allrows[1]);
+ }
+ }
+ catch (err)
+ {
+ }
+ }
+
+ var language = null;
+ try
+ {
+ language = JqueryPortico.i18n.datatable();
+ }
+ catch (err)
+ {
+ }
+
data = data || {};
if (ajax_url)
@@ -351,7 +380,7 @@
}*/
},
lengthMenu: lengthMenu,
- // language: JqueryPortico.i18n.datatable(),
+ language: language,
columns: columns,
// stateSave: true,
// stateDuration: -1, //sessionstorage
Modified: trunk/phpgwapi/templates/base/datatable_inline.xsl
===================================================================
--- trunk/phpgwapi/templates/base/datatable_inline.xsl 2016-03-04 09:55:24 UTC
(rev 14807)
+++ trunk/phpgwapi/templates/base/datatable_inline.xsl 2016-03-04 10:14:46 UTC
(rev 14808)
@@ -342,6 +342,9 @@
var options<xsl:number value="($num - 1)"/> = {};
<xsl:for-each select="$config">
+ <xsl:if test="allrows">
+ options<xsl:number value="($num - 1)"/>.allrows
= true;
+ </xsl:if>
<xsl:if test="singleSelect">
options<xsl:number value="($num -
1)"/>.singleSelect = true;
</xsl:if>
Modified: trunk/property/inc/class.uicondition_survey.inc.php
===================================================================
--- trunk/property/inc/class.uicondition_survey.inc.php 2016-03-04 09:55:24 UTC
(rev 14807)
+++ trunk/property/inc/class.uicondition_survey.inc.php 2016-03-04 10:14:46 UTC
(rev 14808)
@@ -473,7 +473,10 @@
'container' => 'datatable-container_1',
'requestUrl' =>
json_encode(self::link(array('menuaction' =>
'property.uicondition_survey.get_request',
'id' => $id, 'phpgw_return_as'
=> 'json'))),
- 'ColumnDefs' => $related_def
+ 'ColumnDefs' => $related_def,
+ 'config' => array(
+ array('allrows' => true),
+ )
);
$summation_def = array
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Fmsystem-commits] [14808] translations and allrows for inline tables,
Sigurd Nes <=