Hi,

 Every model in my project does have a 'created_by' and 'modified_by'
field, storing some user ID.
 Currently, I'm using a controller beforeFilter to populate a
temporary Model with the $this->Auth->user() , only if $this->data is
full of something, and a beforeSave in the Model, to associate that
temporary fields to the model being saved.
 Actually, I don't quite like this approach, but couldn't think of
something better, since a Model can't access the Auth component. Or
could it ?
 Is there a better way to write it ?

  thanks
  Spark

-- 
[livesets] http://djspark.com.br/
[web] http://sydi.net
[filmes] http://melhoresfilmes.com.br

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" 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/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to