fmsystem-commits
[Top][All Lists]
Advanced

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

[Fmsystem-commits] [13816] more on controller


From: Sigurd Nes
Subject: [Fmsystem-commits] [13816] more on controller
Date: Mon, 31 Aug 2015 17:49:51 +0000

Revision: 13816
          http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=13816
Author:   sigurdne
Date:     2015-08-31 17:49:50 +0000 (Mon, 31 Aug 2015)
Log Message:
-----------
more on controller

Modified Paths:
--------------
    branches/dev-syncromind/property/inc/class.uientity.inc.php
    branches/dev-syncromind/property/templates/base/entity.xsl

Modified: branches/dev-syncromind/property/inc/class.uientity.inc.php
===================================================================
--- branches/dev-syncromind/property/inc/class.uientity.inc.php 2015-08-31 
12:29:36 UTC (rev 13815)
+++ branches/dev-syncromind/property/inc/class.uientity.inc.php 2015-08-31 
17:49:50 UTC (rev 13816)
@@ -3205,7 +3205,9 @@
 //                             $entry['select'] = "<input type='checkbox' 
class='mychecks' value='{$entry['serie_id']}'></input>";
                        }
 
-                       if( phpgw::get_var('phpgw_return_as') == 'json' && 
!$skip_json)
+                       $phpgw_return_as = phpgw::get_var('phpgw_return_as');
+
+                       if( ($phpgw_return_as == 'json' && $skip_json) || 
$phpgw_return_as != 'json')
                        {
                                return $controls;
                        }
@@ -3322,15 +3324,14 @@
 
                        if( phpgw::get_var('phpgw_return_as') == 'json' )
                        {
+                               $result_data = array
+                               (
+                                       'results' => $_cases,
+                                       'total_records' => count($_cases),
+                                       'draw' => phpgw::get_var('draw', 'int')
+                               );
 
-                               if(count($_cases))
-                               {
-                                       return json_encode($_cases);
-                               }
-                               else
-                               {
-                                       return "";
-                               }
+                               return $this->jquery_results($result_data);
                        }
                        return $_cases;
 

Modified: branches/dev-syncromind/property/templates/base/entity.xsl
===================================================================
--- branches/dev-syncromind/property/templates/base/entity.xsl  2015-08-31 
12:29:36 UTC (rev 13815)
+++ branches/dev-syncromind/property/templates/base/entity.xsl  2015-08-31 
17:49:50 UTC (rev 13816)
@@ -284,6 +284,9 @@
                <xsl:choose>
                        <xsl:when test="mode = 'edit'">
                                <script type="text/javascript">
+                                       var location_id = '<xsl:value-of 
select="value_location_id"/>';
+                                       var item_id = '<xsl:value-of 
select="value_id"/>';
+
                                        function set_tab(active_tab)
                                        {
                                                document.form.active_tab.value 
= active_tab;




reply via email to

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