Author: francois
Date: 2010-05-07 09:15:56 +0200 (Fri, 07 May 2010)
New Revision: 29383
Modified:
plugins/sfPropel15Plugin/trunk/lib/task/sfPropelGenerateAdminTask.class.php
Log:
[sfPropel15Plugin] Using the new routes as default for the admin generator
Modified:
plugins/sfPropel15Plugin/trunk/lib/task/sfPropelGenerateAdminTask.class.php
===================================================================
--- plugins/sfPropel15Plugin/trunk/lib/task/sfPropelGenerateAdminTask.class.php
2010-05-07 07:15:19 UTC (rev 29382)
+++ plugins/sfPropel15Plugin/trunk/lib/task/sfPropelGenerateAdminTask.class.php
2010-05-07 07:15:56 UTC (rev 29383)
@@ -32,7 +32,7 @@
$this->addOptions(array(
new sfCommandOption('module', null, sfCommandOption::PARAMETER_REQUIRED,
'The module name', null),
- new sfCommandOption('theme', null, sfCommandOption::PARAMETER_REQUIRED,
'The theme name', 'admin'),
+ new sfCommandOption('theme', null, sfCommandOption::PARAMETER_REQUIRED,
'The theme name', 'admin15'),
new sfCommandOption('singular', null,
sfCommandOption::PARAMETER_REQUIRED, 'The singular name', null),
new sfCommandOption('plural', null, sfCommandOption::PARAMETER_REQUIRED,
'The plural name', null),
new sfCommandOption('env', null, sfCommandOption::PARAMETER_REQUIRED,
'The environment', 'dev'),
@@ -64,7 +64,7 @@
the [with_wildcard_routes|COMMENT] option to the route:
article:
- class: sfPropelRouteCollection
+ class: sfPropel15RouteCollection
options:
model: Article
with_wildcard_routes: true
@@ -120,7 +120,7 @@
$module = $options['module'] ? $options['module'] : $name;
$content = sprintf(<<<EOF
%s:
- class: sfPropelRouteCollection
+ class: sfPropel15RouteCollection
options:
model: %s
module: %s
@@ -146,7 +146,7 @@
{
$routeOptions = $arguments['route']->getOptions();
- if (!$arguments['route'] instanceof sfPropelRouteCollection)
+ if (!$arguments['route'] instanceof sfPropel15RouteCollection)
{
throw new sfCommandException(sprintf('The route "%s" is not a Propel
collection route.', $arguments['route_name']));
}
@@ -197,7 +197,7 @@
*/
protected function checkRoute($route, $model, $module)
{
- if ($route instanceof sfPropelRouteCollection)
+ if ($route instanceof sfPropel15RouteCollection)
{
$options = $route->getOptions();
return $model == $options['model'] && $module == $options['module'];
--
You received this message because you are subscribed to the Google Groups
"symfony SVN" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/symfony-svn?hl=en.