Add Account to Document Automatically

Hello guys,

Im uploading documents to suitecrm with de Document Module. I really want to know, how to associate the document to Account automatically. Because, when i finish to create it, i need to go to Accounts panel on Documents Module and select the Account.

The idea is select the account when im creating and uploading the new document.

Thank you All!

(sorry for my english)

There are several ways to approach this.

Maybe it’s easier for you to go first into the Account detail view, scroll down to the Documents subpanel, and hit “Create”. This will be practical if upload several documents from the same account in sequence.

Another way, if you always link to the same Account, is to create a Workflow: when a Document is saved, link it to Account X.

If you need full programmatic control, use an after_save logic hook on the Documents module. This is if you need to decide which account to link to based on a more complex condition, like filename, or any field value.