Hi every one, I'm using Symfony for a time and now I'm re-factorizing some code and I face something that I don't know how to solve:
Using: Symfony 1.4, PHP 5.3 , MySQL, Linux By the I create a Doctrine Behavior : <?php class VotableBehavior extends Doctrine_Record_Generator { protected $_options = array ( 'className'=>'%CLASS%Votes', 'generateFiles'=>true, 'children'=> array (), 'builderOptions'=> array ('BaseClassesDirectory'=>'base', 'Suffix'=>'.class.php'), 'options'=> array () ); public function __construct( array $options) { $this->_options = Doctrine_Lib::arrayDeepMerge($this- >_options, $options); } public function initOptions() { $dir = sfConfig::get('sf_lib_dir')."/model/doctrine/"; $this->setOption('generatePath', $dir); } public function setTableDefinition() { $class_table = $this->_options['table']; $this->setTableName($class_table->getTableName().'_votes'); $this->hasColumn('id', 'integer', 11, array ('type'=>'integer', 'length'=>11, 'primary'=>true, 'autoincrement'=>true)); $this->hasColumn('vote', 'boolean', null, array ('type'=>'boolean' )); $this->hasColumn($class_table->getTableName().'_id', 'integer', 11, array ('type'=>'integer', 'length'=>11, 'notnull'=>true)); } public function setUp() { $this->actAs( new Doctrine_Template_Timestampable()); $this->actAs( new Userable()); } public function buildRelation() { $this->buildForeignRelation("votes"); $this->buildLocalRelation(); } public function buildLocalRelation($alias = null) { $options = array('local' => $this->_options['table']- >getTableName().'_id', 'foreign' => $this->_options['table']- >getIdentifier(), 'type' => Doctrine_Relation::MANY); $options['type'] = Doctrine_Relation::ONE; $options['onDelete'] = 'CASCADE'; $options['onUpdate'] = 'CASCADE'; $this->_table->getRelationParser()->bind($this- >_options['table']->getComponentName(), $options); } } When I make ./symfony doctrine:build-form and ./symfony doctrine:build- filter, symfony builds forms and filters for this Relational Model. I'vew tried: .... protected $_options = array ( 'className'=>'%CLASS%Votes', 'generateFiles'=>true, 'children'=> array (), 'builderOptions'=> array ('BaseClassesDirectory'=>'base', 'Suffix'=>'.class.php'), 'options'=> array ( 'symfony' => array ( 'form' => false, 'filter' => false ) ) ); .... But not working! If anyone could help to configure the behavior to not create Forms and Filters, I'll appreciate it Thanks Best Regards Jose Antonio Pio Acilia Internet S.L. Madrid Spain -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups "symfony users" group. To post to this group, send email to symfony-users@googlegroups.com To unsubscribe from this group, send email to symfony-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-users?hl=en