Hello,

I'm currently looking into implementing created_on/by & updated_on/by
in my CakePHP based webapplication and I am wondering what the best way
to implement this would be.

I need:
* on creation (of a Model record?) : fill created_on/by
* on save (of a Model record?) : fill updated_on/by

I'm assuming:
* creation implies a save will occur later (so both created_ and
updated_ will be filled
* a login system (i.e. rdAuth) is present and the user id is known in
the controller (to fill the xxx_by fields
* the xxx_on field contain the system time on creation/update

I'm not sure if this logic should be done in the (App) Model for me or
not (by overriding the create and save functions, but then how do I
'neatly' access the user id from the Model?

Best regards,

Jeroen Janssen


--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to