From ffdd98ac237f6c07626920bc0ddaf730c71a3d0c Mon Sep 17 00:00:00 2001 From: Andrey Kutejko Date: Wed, 4 Sep 2013 19:48:09 +0300 Subject: [PATCH] no more project level models --- ipf/command/buildmodels.php | 17 +++-------------- 1 file changed, 3 insertions(+), 14 deletions(-) diff --git a/ipf/command/buildmodels.php b/ipf/command/buildmodels.php index fd9e50a..41e19d9 100644 --- a/ipf/command/buildmodels.php +++ b/ipf/command/buildmodels.php @@ -12,10 +12,9 @@ class IPF_Command_BuildModels $project = IPF_Project::getInstance(); $extraAllowedReferences = $this->frameworkModels($project); - foreach ($this->paths($project) as $p) { - list($name, $path) = $p; - print "$name\n"; - $models = IPF_ORM::generateModelsFromYaml($path, $extraAllowedReferences); + foreach ($project->customApps() as $app) { + print $app->getName()."\n"; + $models = IPF_ORM::generateModelsFromYaml($app->getPath(), $extraAllowedReferences); $extraAllowedReferences = array_merge($extraAllowedReferences, $models); } } @@ -27,15 +26,5 @@ class IPF_Command_BuildModels $models = array_merge($models, $app->modelList()); return $models; } - - private function paths($project) - { - $paths = array( - array('Project', IPF::get('project_path')), - ); - foreach ($project->customApps() as $app) - $paths[] = array($app->getName(), $app->getPath()); - return $paths; - } } -- 2.49.0