Might be worth noting I'm trying to write a behavior that will, - Add extra fields to a table the behavior is applied to - Add extra methods to the model class - Add hooks into the peer methods
I think I know how to add extra methods and hooks, but I'm struggling to figure out how to get the behavor to alter the table using modifyDatabase(). If I run build-model or build-sql by themselves, the modifyDatabase() method on my behavior doesn't even run, so I don't know how to hook it up into the build process properly it would seem. Thanks. On 25 May 2010 11:48, Stephen Melrose <step...@sekka.co.uk> wrote: > Hi, > > I'm trying to add a custom behavior to my project, but when I run > propel:build-all I keep getting the following error, > > 'Propel behavior "previewable" is not registered' > > I'm pretty sure I'm missing something stupid here, but I need a fresh > pair of eyes. > > I've added a class called mbpPropelActAsPreviewableBehavior in lib/ > behavior/mbpPropelActAsPreviewableBehavior.php. > > In my propel.ini, I've added after all the symfony behavior settings > the following, > > propel.behavior.previewable.class = > lib.behavior.mbpPropelActAsPreviewableBehavior > > And in my schema I've added, > > myTable: > _attributes:{ phpName: MyTable } > id: ~ > _behaviors: > previewable: [] > > But I'm still getting the error stated above. Does anyone know where > I'm going wrong? > > Thanks, > > Steve > -- 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