DataObjects/Builder_tables.php
[Pman.Builder] / Palette.php
index a8bd056..1031eb3 100644 (file)
@@ -16,7 +16,51 @@ class Pman_Builder_Palette extends Pman
         }
         // list of properties or events.
         // gets xns+xtype+list
+        $ff = HTML_FlexyFramework::get();
         
+        $cls = $_REQUEST['xns'] . '.' . $_REQUEST['xtype'];
+        
+        $data = json_decode(file_get_contents($ff->rootDir . '/roojs1/docs/json/roodata.json'));
+        
+        //echo '<PRE>'; print_R($data);
+        
+        $out = $data->data->{ $cls } -> {$_REQUEST['list'] };
+        if ($sub == 'Prop') {
+            foreach(array(
+                array(
+                    'name' => "builder.sharedname",
+                    'desc'  => "This is a shared part, between different parts (modifying it will change other pages",
+                    'memberOf' => "Builder",
+                    
+                    'type' => "Boolean"
+                ),
+                
+                array(
+                    'name' => "flexy:foreach",
+                    'desc'  => "Loop foreach (array,key,val|array,val)",
+                    'memberOf' => "Flexy",
+                    
+                    'type' => "String"
+                ),
+                array(
+                    'name' => "flexy:if",
+                    'desc'  => "if condition - put 0 to always disable it",
+                    'memberOf' => "Flexy",
+                    
+                    'type' => "String"
+                ),
+                  
+                
+            ) as  $add) {
+                array_push($out,$add);
+            }
+  
+            
+            
+         
+        }
+        $this->jdata($out );
+              
         // 
         
     }
@@ -24,9 +68,8 @@ class Pman_Builder_Palette extends Pman
     {
         
         // use file..
-        // get this directly from roo?
+        // this is our hand made file at present.. shared with app.Builders code.
         
-        print_R(FlexyFramework::get());exit;
         $lines = file(dirname(__FILE__).'/RooUsage.txt');
         $s = -1;
         $res = array();
@@ -74,6 +117,10 @@ class Pman_Builder_Palette extends Pman
                 'parents' =>  array_keys($v) 
             );
         }
+        
+       // echo '<PRE>';print_r($ret);
+       
+        
         $this->jdata($ret);
         //echo '<PRE>';print_R($ret);exit;
     }