You can set it in model or controller, doesn't matter (as long as you don't
make database queries inside models, which you probably don't do).

Yes, you can append multiple callbacks. Web2py can use these lists for
internal stuff, so you should only append to it.

Marin


On Sun, Jun 9, 2013 at 2:14 PM, Tim Richardson <t...@tim-richardson.net>wrote:

>
> What does "append" hint at in the naming of the  hooks for data base
> events?
> I want to do something when a record is deleted from a grid.
> Is there any harm if I call _before_delete.append in the controller
> function, or should the callback be set in the model?
> I guess it doesn't matter since both the model and the controller function
> are executed after the form action, but I would like to be sure.
>
> Does append mean that multiple callbacks can be set up?
>
> --
>
> ---
> You received this message because you are subscribed to the Google Groups
> "web2py-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to web2py+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to