Creating Multiple invoices from a single contract (multiple records from a single record)
Posted on 2006-07-20
I wrote in a while back about a client contract/invoice database. The advice previously was excellent and the database works very well. However, there is now a need for added functionality that is counter to how I'd built the database initially. The database works on a contract/invoice structure where there is a 1-to-1 relationship between contracts and invoices. A contract is generated and there is also an invoice generated. The system worked very well. Now, however, there is a need to be able to insert multiple items in the contract that need separate invoices, so the 1-to-1 relationship no longer works. For example, a contract would include advertisements for Jan, Feb and Mar issues. All three would appear on one contract but individual invoices need to be generated for each month, along with the functionality to be able to generate those invoices in their respective months rather than all at once.
I've tried a number of scripting solutions, but none create the desired effect.
Any advice for a fix?