>
> 1) In the calling page first call the department.edit() method of the
> department component directly followed by the
> auditTrail.log() method of the
> audit trail.
No.
> 2) In the calling page call the department.edit() method of
> the department
> component. In the department component, in the edit method call the
> auditTrail.log() method.
Yes. Let the Department CFC worry about it.
>
> Of course keep in mind that I'm going to have to call the auditTrail
> component every time an insert, edit or delete action is made... Is it
> better / more oop (not that I know exactly when I'm
> respecting/violating the
> rules of OOP as it is) to do number 1, 2 or is there some
> other option I
> should be considering?
>
Along with invoking log on auditTrail from Department, you could also
have Department inherit auditTrail, that way your code is a bit simpler
- you could do this after the meat of your method,
<cfset log(........)>
instead of:
<cfinvoke component="auditTrail" method="log">
<cfinvokeargument ....>
</cfinvoke>
=======================================================================
Raymond Camden, ColdFusion Jedi Master for Macromedia
Email : [EMAIL PROTECTED]
Yahoo IM : morpheus
"My ally is the Force, and a powerful ally it is." - Yoda
______________________________________________________________________
This list and all House of Fusion resources hosted by CFHosting.com. The place for
dependable ColdFusion Hosting.
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists