Business management tools like customer management (CRM), purchasing (SCM), human resources (HR), production and warehouse (MRP), etc, use and generate a huge amount of documents like budgets, invoices, contracts, e-mail messages and many others.
Dealing with all these content, including theire classification, organization and availability to be searchable is critical to business efficiency.
The solution developed by Multibase for Odoo ERP allows all documents generated by the ERP (like invoices, contracts, pictures, etc.) to be stored into a company defined structure, dynamically by model in the document management system. As a example, invoices can be archived by year and by month, contracts and documents from the employee can be archieved by type and by employee, reports can be archieved by type, etc.
The main features of this solution are described in the following points. For more information please contact us.
Name: Odoo/Nuxeo Integration
Technical name: mb_ecm_odoo_nuxeo
The module uses the cmislib bridge for Odoo developed by Multibase and available from mb_cmislib_odoo module. This bridge allows an easier implementation for the various operations needed by the module.
The configuration screen is found in the Odoo's company settings (Settings > Companies > Archive Configuration), as shown below:
Module configuration fields
Nuxeo URL:Full Nuxeo CMIS URL (e.g. http://example.com:8080/nuxeo/atom/cmis)
Password:Nuxeo password (Documents will be created using this user. Document access rights can be managing via Nuxeo ACL)
"Test Connection" button:When invoked, it will try to connect to Nuxeo with the specified details above and will return a response whether the connection is successful or not.
"Call Nuxeo" button: When invoked, it will call the module's main routine, which is to process attachments and send them to the specified Nuxeo server, using a path configuration.
"Process attachments?" checkbox:To activate the module and process attachments by sending them to Nuxeo according to Model Associations configuration.
Model Associations:The majority of models (or objects) in Odoo can have documents attached to them. This field allows us to specify custom nuxeo paths for each one. Each entry in this one2many field is called a model association
Creating a model association
After clicking on "Add an item" on the list, the following modal box is displayed:
Model name: Name of the model (or object) to process attachments of (e.g. res.partner).
Root path: Nuxeo repository base directory. This folder must be already created.
Path Association: This field allows to create dynamic paths in Nuxeo, using the data from the model entry associated with. For example, using Odoo's CRM module, we can have a folder named "Partners" and in that folder dynamically create subfolders for each partner, using his name or any other field in the model. (See bellow how to create a path association)
Active: Whether the model association is active or not. If not active, the model's attachements will be ignored.
Creating a path association
There are three type of values you can use to create the path structure:
Static folder name
An attachment's filename
The value of a field in the model
The value of a field on another model, referenced by a one2many field.
Specifying date fields
For the path association, we have a checkbox which is called "Is datetime field". Its purpose is to indicate that the parameter or the referenced field name is a date or datetime type of field.
Data field type
Indicates the type of date time field.
Datetime format string
A string which accepts python's _strftime()_ formatting.
"Accounting %Y" will be converted to "Accounting 2014"
"%Y-%m-%d" will be converted to "2015-10-24"
It is possible to create a path association by parsing the attachment's filename and saving it to a specific folder. This is useful in case a model generates more than one report and we have to archive them in different folders.
When we select this option, we have to fill in two fields:
Indicates the type of lookup. Available options are:
- Start of string
- End of string
- String includes
The string to search for in the filename, according to to the lookup type defined above.
The following example is an invoice structure, sorted by date. The final path configuration will be:
< month and year > / "Customer Invoices" or "Supplier Invoices" / Customer's name
The model association will look like this:
First, the date field:
Assuming the customers' invoices start with "INVC", the association will be:
Assuming the suppliers' invoices start with "INVS", the association will be:
Finally, for the Customer's / Supplier's name:
There are two ways of running the export process.
When the "Process attachments" checkbox is selected, the module will automatically create a scheduled action and will run, by default, every 5 minutes.
The process can be executed manually by clicking the "Archive Documents" button.