I tried it: when I enable the behavior in the class itself, it fills
out the created_by, updated_by and deleted_by columns, but enabling
the behavior in the custom.yml -without messing in the generated
classes for the plugin- it doesn't work at all...

And even the paranoid-behavior is not "registered" either.

P.S. When I just use...
     _behaviors:
      paranoid:    { column: deleted_at }
...the paranoid behavior works fine.

And when using only the sfPropelActAsSignableBehavior...
     _behaviors:
      sfPropelActAsSignableBehavior: { columns: { created: created_by,
updated: updated_by, deleted: deleted_by} }
...the sfPropelActAsSignableBehavior doesn't work either.

So I have the feeling that I'm not using the right name to specify the
behavior? "sfPropelActAsSignableBehavior" seems to me to be the right
name to specify it, but apparently that is not right...

Why is the sfPropelParanoidBehaviorPlugin enabled by specifying
"paranoid"?
My guess is that it just picks up the name, specified in the
sfPropelParanoidBehaviorPlugin's config-file (first parameter of the
registerHooks-method):

sfPropelBehavior::registerMethods('paranoid', array(
  array('sfPropelParanoidBehavior', 'forceDelete'),
));

sfPropelBehavior::registerHooks('paranoid', array(
  ':delete:pre' => array('sfPropelParanoidBehavior', 'preDelete'),
  'Peer:doSelectRS' => array('sfPropelParanoidBehavior',
'doSelectRS'),
));

Or am I totally mistaking?

On May 2, 4:28 pm, "Francois Zaninotto" <[EMAIL PROTECTED]
project.com> wrote:
> Yes, it should work like that. Did you try it ?
>
> François
>
> 2008/5/2 djoos <[EMAIL PROTECTED]>:
>
>
>
> > When making use of the sfPropelAlternativeSchemaPlugin (and modifying
> > the settings for the builder in propel.ini - as described on the
> > plugin's page), it is possible to use custom schema's for plugin
> > defined schema's by defining a PluginName_schema.custom.yml-file in
> > your config folder.
>
> > In the custom schema it is possible to enable behaviors, eg.:
> >  sf_guard_permission:
> >    _attributes:   { phpName: sfGuardPermission, package:
> > plugins.sfGuardPlugin.lib.model }
> >    created_at:    { type: TIMESTAMP, description: "When was this
> > record created?" }
> >    created_by:    { type: VARCHAR, size: 255, description: "Who
> > created this record?" }
> >    updated_at:    { type: TIMESTAMP, description: "When was this
> > record updated?" }
> >    updated_by:    { type: VARCHAR, size: 255, description: "Who
> > updated this record?" }
> >    deleted_at:    { type: TIMESTAMP, description: "When was this
> > record deleted?" }
> >    deleted_by:    { type: VARCHAR, size: 255, description: "Who
> > deleted this record?" }
> >    _behaviors:
> >      paranoid:    { column: deleted_at }
>
> > But is it -and if so, how?- possible to enable multiple behaviors,
> > eg.:
> >    _behaviors:
> >      paranoid:    { column: deleted_at }
> >      sfPropelActAsSignableBehavior: { columns: { created: created_by,
> > updated: updated_by, deleted: deleted_by} }
>
> > Thanks!
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"symfony developers" 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-devs?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to