[LRUG] Setting default roles in a user record

David Nolan dave at textgoeshere.org.uk
Wed Aug 8 01:06:43 PDT 2007


Apologies if already mentioned, but I've used this plugin plenty:
http://agilewebdevelopment.com/plugins/activerecord_defaults

Behind the scenes it aliases initialize as discussed, you can pass it blocks
etc, and it does a good job of handling associations.

As for debugging, having lines in your model(s) like:

default :name => :roque_santa_cruz

...is clear enough for me.

D
-- 
Dave Nolan
mob: 07966 517 584
tel: 0845 458 7495
http://textgoeshere.org.uk
online publishing from start to finish
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lrug.org/pipermail/chat-lrug.org/attachments/20070808/72e38be7/attachment-0003.html>


More information about the Chat mailing list