]> git.andy128k.dev Git - ipf.git/commitdiff
verbose model builder
authorAndrey Kutejko <andy128k@gmail.com>
Thu, 11 Jul 2013 18:58:30 +0000 (21:58 +0300)
committerAndrey Kutejko <andy128k@gmail.com>
Thu, 11 Jul 2013 18:58:30 +0000 (21:58 +0300)
ipf/command/buildmodels.php

index 8308ac9890bbaa9fdaba1457598cd2cebe29de7a..17dae54502d2b6e9bf5ded25c200f0ce1e5ffda6 100644 (file)
@@ -7,12 +7,14 @@ class IPF_Command_BuildModels
 
     public function run($args=null)
     {
-        print "Build all model classes\n";
+        print "Build all model classes\n\n";
 
         $project = IPF_Project::getInstance();
 
         $extraAllwedReferences = $this->frameworkModels($project);
-        foreach ($this->paths($project) as $path) {
+        foreach ($this->paths($project) as $p) {
+            list($name, $path) = $p;
+            print "$name\n";
             $models = IPF_ORM::generateModelsFromYaml($path, $extraAllwedReferences);
             $extraAllwedReferences = array_merge($extraAllwedReferences, $models);
         }
@@ -29,10 +31,10 @@ class IPF_Command_BuildModels
     private function paths($project)
     {
         $paths = array(
-            IPF::get('project_path'),
+            array('Project', IPF::get('project_path')),
         );
         foreach ($project->customApps() as $app)
-            $paths[] = $app->path;
+            $paths[] = array($app->getName(), $app->getPath());
         return $paths;
     }
 }