fmsystem-commits
[Top][All Lists]
Advanced

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

[Fmsystem-commits] [11270] more on logistic


From: Sigurd Nes
Subject: [Fmsystem-commits] [11270] more on logistic
Date: Thu, 29 Aug 2013 09:26:00 +0000

Revision: 11270
          http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=11270
Author:   sigurdne
Date:     2013-08-29 09:26:00 +0000 (Thu, 29 Aug 2013)
Log Message:
-----------
more on logistic

Modified Paths:
--------------
    trunk/logistic/inc/class.soactivity.inc.php
    trunk/logistic/inc/class.uiactivity.inc.php
    trunk/logistic/templates/base/activity/view_activity_item.xsl

Modified: trunk/logistic/inc/class.soactivity.inc.php
===================================================================
--- trunk/logistic/inc/class.soactivity.inc.php 2013-08-28 13:42:46 UTC (rev 
11269)
+++ trunk/logistic/inc/class.soactivity.inc.php 2013-08-29 09:26:00 UTC (rev 
11270)
@@ -246,7 +246,12 @@
                        return null;
                }
 
+               public function get_count(string $search_for, string 
$search_type, array $filters)
+               {
+                       return $this->total_records;
+               }
 
+
                /**
                 * used for retrive the path for a particular node from a 
hierarchy
                 *

Modified: trunk/logistic/inc/class.uiactivity.inc.php
===================================================================
--- trunk/logistic/inc/class.uiactivity.inc.php 2013-08-28 13:42:46 UTC (rev 
11269)
+++ trunk/logistic/inc/class.uiactivity.inc.php 2013-08-29 09:26:00 UTC (rev 
11270)
@@ -314,13 +314,15 @@
                        switch ($query_type)
                        {
                                case 'children':
-                                       $num_of_objects = null;//get them all
                                        $activity_id = 
phpgw::get_var('activity_id');
                                        $filters = array('id' => $activity_id);
-                                       $result_objects = 
$this->so->get($start_index, $num_of_objects, $sort_field, $sort_ascending, 
$search_for, $search_type, $filters,true);
-                                       $object_count = 
$this->so->get_count($search_for, $search_type, $filters);
-
+                                       $result_objects = 
$this->so->get($start_index, $num_of_objects, $sort_field, $sort_ascending, 
$search_for, $search_type, $filters);
+                                       $object_count = $this->so->get_count();
                                        array_shift($result_objects);
+                                       if($result_objects)
+                                       {
+                                               $object_count --;
+                                       }
                                        break;
                                case 'activity_id':
                                        $activity_id = 
phpgw::get_var('activity_id');
@@ -389,7 +391,6 @@
                                }
                        }
 
-
                        // ... add result data
                        $result_data = array('results' => $rows);
 

Modified: trunk/logistic/templates/base/activity/view_activity_item.xsl
===================================================================
--- trunk/logistic/templates/base/activity/view_activity_item.xsl       
2013-08-28 13:42:46 UTC (rev 11269)
+++ trunk/logistic/templates/base/activity/view_activity_item.xsl       
2013-08-29 09:26:00 UTC (rev 11270)
@@ -86,19 +86,18 @@
    var oArgs = {
                                        menuaction:'logistic.uiactivity.index',
                                        activity_id: '<xsl:value-of 
select='activity/id'/>',
-                                       type: 'children',
-                                       phpgw_return_as: 'json'
+                                       type: 'children'
                                };
                        
                var requestUrl = phpGWLink('index.php', oArgs, true);
                        
                var myColumnDefs = [ 
-               {key:"id", label:'Id', sortable:true},
-               {key:"name", label:'Aktivitetsnavn', sortable:true},
-               {key:"start_date", label:'Startdato', sortable:true}, 
-               {key:"end_date", label:'Sluttdato', sortable:true},
-                       {key:"responsible_user_name", label:'Ansvarlig', 
sortable:true},
-                       {key:"status", label:'Status', sortable:true}
+               {key:"id", label:'Id', sortable:false},
+               {key:"name", label:'Aktivitetsnavn', sortable:false},
+               {key:"start_date", label:'Startdato', sortable:false}, 
+               {key:"end_date", label:'Sluttdato', sortable:false},
+                       {key:"responsible_user_name", label:'Ansvarlig', 
sortable:false},
+                       {key:"status", label:'Status', sortable:false}
            ]; 
 
                YAHOO.portico.inlineTableHelper("sub-activities-container", 
requestUrl, myColumnDefs);




reply via email to

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