Pman/Roo.php
authorAlan Knowles <alan@roojs.com>
Tue, 21 May 2019 08:29:40 +0000 (16:29 +0800)
committerAlan Knowles <alan@roojs.com>
Tue, 21 May 2019 08:29:40 +0000 (16:29 +0800)
Pman/Roo.php

index 21339a2..8866e22 100644 (file)
@@ -467,11 +467,7 @@ class Pman_Roo extends Pman
                         $titles = explode(',', $titles);
                     }
                     foreach($cols as $i=>$col) {
-                        if (method_exists($data, 'toSimpleExcelRow')) {
-                            
-                        }
-                        
-                        $se_config['cols'][] = array(
+                        $add = array(
                             'header'=> isset($titles[$i]) ? $titles[$i] : $col,
                             'dataIndex'=> $col,
                             'width'=>  100,
@@ -480,6 +476,12 @@ class Pman_Roo extends Pman
                               // 'fillBlank' => 'gray', // set 
                         );
                         
+                        if (method_exists($data, 'toSimpleExcelCol')) {
+                            $add = $data->toSimpleExcelColumn($col);
+                        } 
+                        
+                        $se_config['cols'][] = $add;
+                        
        
                         
                     }