Recurring Invoices

When trying to set up a recurring invoicing regime, I have taken the path of running it using a scheduled task and a custom module.
It’s very flexible, and can be completely automated.

The idea is that you create a custom scheduled task (which can run daily). This goes through your list of accounts looking for your custom module (Recurring Invoice) which sets up the details for the Invoice. These details can be day of month/year in which invoice is generated, $amount, Description, etc… Then it generates an unpaid Invoice, and links it to the account.

It’s the same basic concepts required to write a logic hook.

Help with custom task schedulers:
http://support.sugarcrm.com/Documentation/Sugar_Developer/Sugar_Developer_Guide_6.5/Application_Framework/Job_Queue/Schedulers/Custom_Schedulers/

Help with relationships within custom modules
https://developer.sugarcrm.com/2013/05/29/programmatically-find-the-name-of-the-relationship-between-two-modules/

Reminder that the relationships must be loaded before they are set…
https://suitecrm.com/community/developer-help/10257-add-relationship-between-2-modules-during-other-logic-hooks-process#35150