fmsystem-commits
[Top][All Lists]
Advanced

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

[Fmsystem-commits] [12474] change index


From: Nelson Guerra
Subject: [Fmsystem-commits] [12474] change index
Date: Tue, 16 Dec 2014 23:22:26 +0000

Revision: 12474
          http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=12474
Author:   nelson224
Date:     2014-12-16 23:22:25 +0000 (Tue, 16 Dec 2014)
Log Message:
-----------
change index

Modified Paths:
--------------
    branches/dev-syncromind/property/inc/class.uiwo_hour.inc.php

Modified: branches/dev-syncromind/property/inc/class.uiwo_hour.inc.php
===================================================================
--- branches/dev-syncromind/property/inc/class.uiwo_hour.inc.php        
2014-12-16 23:21:49 UTC (rev 12473)
+++ branches/dev-syncromind/property/inc/class.uiwo_hour.inc.php        
2014-12-16 23:22:25 UTC (rev 12474)
@@ -702,9 +702,6 @@
                                return $this->query();
                        }
                        
-                       self::add_javascript('phpgwapi', 'jquery', 
'editable/jquery.jeditable.js');
-                       self::add_javascript('phpgwapi', 'jquery', 
'editable/jquery.dataTables.editable.js');
-                       
                        $appname        = lang('Workorder');
                        $function_msg   = lang('list hours');
                        
@@ -897,9 +894,9 @@
                        );
                                                                
                        $uicols = array (
-                               'name'                  =>      
array('hour_id','post','code','hours_descr','unit_name','billperae','quantity','cost','deviation','result','wo_hour_category','cat_per_cent'),
-                               'input_type'    =>      
array('hidden','text','text','text','text','text','text','text','text','text','text','text'),
-                               'descr'                 =>      
array('',lang('Post'),lang('Code'),lang('Descr'),lang('Unit'),lang('Bill per 
unit'),lang('Quantity'),lang('Cost'),lang('deviation'),lang('result'),lang('Category'),lang('percent'))
+                               'name'                  =>      
array('post','code','hours_descr','unit_name','billperae','quantity','cost','deviation','result','wo_hour_category','cat_per_cent'),
+                               'input_type'    =>      
array('text','text','text','text','text','text','text','text','text','text','text'),
+                               'descr'                 =>      
array(lang('Post'),lang('Code'),lang('Descr'),lang('Unit'),lang('Bill per 
unit'),lang('Quantity'),lang('Cost'),lang('deviation'),lang('result'),lang('Category'),lang('percent'))
                        );
 
                        $count_uicols_name = count($uicols['name']);
@@ -996,6 +993,21 @@
 
                        unset($parameters);                             
 
+                       $common_data = $this->common_data($workorder_id);
+                       $content = $common_data['content'];
+                       $values = array();
+                       $k = 0;
+                       foreach ($content as $row)
+                       {
+                               foreach ($uicols['name'] as $name) 
+                               {
+                                       $values[$k][] = $row[$name];
+                               }
+                               $k ++;
+                       }
+
+                       $data['datatable']['data'] = json_encode($values);
+               
                        self::render_template_xsl('wo_hour.index', $data);
 
                        //Title of Page




reply via email to

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