SugarCRM already comes with document upload feature that uploads documents. Today i will discuss with you how to create custom file upload option that you will be using in a module, this will allow user to add multiple files through your custom module and allow to manage them.
Full code can be found here Custom multiple file upload sugarCRM in module to brief it,
You have to follow the steps below.
- Create one custom module that will create relation with your current module and new module (that will save all documents uploaded).
- Create logic hook that will save the uploaded files in upload directory and relationship between these modules.