Odoo ERP Integration

In addition to Patriot's standard billing module features, if you choose the Odoo (previously Open ERP) ERP software to integrate with then additional features are available. These additional features are described in this document and include: inserting, updating and opening Patriot clients from the Odoo web interface, automatically sending invoice details from Patriot to Odoo for formatting and opening Odoo customers from a linked Patriot client.

Patriot support staff can perform a customer data import from your Patriot client database as a one off service when purchasing the Odoo module. Importing your accounting ledger from another software package is not included. It is recommended that you consult with a specialist Odoo systems integrator to help you with the transition to Odoo.

Prerequisites

Patriot Setup

Patriot communicates with Odoo over TCP IP on the same HTTP port used by Odoo web browser clients. This is port 8069 by default in Odoo 9. Note that this port must be open in the Windows/Linux firewall to accept inbound connections from Patriot. Odoo server network and login details are set in the Billing section of Patriot's system wide settings.

Odoo System Wide Settings
Odoo Server login details must be set in Patriot's System Wide Settings.

Odoo communicates back to Patrot over TCP IP on Patriot JSON Service port which is 9001 by default. JSON services must be enabled in the Patriot Data service for this to work. How to enable Patriot's JSON Services is explained here.

Note: the JSON port must opened in the Windows firewall to inbound connections from Odoo.

Odoo Setup

As explained in the previous section, Patriot logs into the Odoo server using an Odoo operator login. The Odoo operator login that you use for this purpose should be given administrator level access rights in Odoo.

Odoo Patriot Operator
Patriot requires it own Odoo operator to login when sending data to Odoo.

Patriot has an add-on Odoo module named Patriot Partner which must be installed on your Odoo service. If you haven't been given a copy of this module with your Odoo module registration, please contact Patriot to obtain a copy. To install the module simply place the "patriot" folder containing the module files into the Odoo server's add-ons directory. The location of the add-ons directory can vary so please check with your Odoo software integrator or refer to the Odoo documentation to locate this directory. To complete the installation, login to Odoo as an administrator, enter the "Developer Mode" via the About menu, and then update your Modules list and finally search for Patriot Partner and select install.

Patriot has an add-on Odoo module which must be installed
Patriot's Odoo module must be installed on your Odoo server.

Once the Patriot Partner module has been installed, it must be configured with the connection details for your Patriot server's JSON services. To do this, remain in the Odoo "Developer Mode" and browse to the Accounting module. In the configuration section, under Patriot, select Settings and enter the details for your Patriot JSON services.

Patriot server connection settings must be set in the Patriot Odoo module settings
Connection settings for your Patriot server's JSON services must be entered in the module settings.

Now that the Patriot module is configured to communicate with Patriot, you must now configure your Patriot Types. A Patriot Type is assigned to every Odoo customer that is linked to either a client[s] or dealer in Patriot. The two main Patriot types are Client and Dealer, but you can have as many of each type as you require. By default the Patriot module installs three types: Residential Client, Commercial Client and Dealer.

Patriot Types let specify how new clients should be inserted in Patriot from Odoo
Patriot Types let specify how different types of Odoo customers should be linked to clients or dealers in Patriot.

Patriot client types require you to set a Patriot Template No. this refers to a client template in Patriot, and is used as a "copy from" template when inserting new Patriot clients from Odoo. You also need to specify Start Client No. and End Client No. which refer to the Patriot client ID range that Odoo will use to pick a free client ID from when inserting new clients. Finally, set the new client Port ID for the Patriot Type. You will usually need to create at least one Patriot Client Type for each of your Patriot receiver port ID's.

The final stage of configuring Patriot's Odoo module is setting up your operators. Once you have the Patriot module installed your can do this in Odoo via: Settings -> Users -> Preferences -> Patriot Operator Settings.

Odoo users should be linked to Patriot operators
Odoo users are linked to Patriot operator accounts.

Because Odoo operators are able to indirectly edit your Patriot client database, each Odoo operator must be linked to a Patriot operator. This is mainly for operator change logging purposes, but it is also useful because it lets operators who work with both software packages to quickly switch between Odoo customers and their linked Patriot clients and vice versa. For this to work you need to specify a Patriot workstation for each of your Odoo operators as well as a Patriot operator account.

Using Patriot with Odoo

Accounting

When you open the Billing Tab of a Patriot client that is linked to an Odoo customer, the Odoo customer is displayed in the Accounting Integration section. You can quickly open the linked customer in the Odoo web interface by clicking the web link button. When a Patriot client is linked to an Odoo customer, it is recommend that you remove Edit access to the billing postal address fields as these should only be edited from Odoo. If the relationship between an Odoo customer and Patriot client is one to one (this will not be the case if the Odoo customer represents a client headquarters or property manager billed for multiple sites), then the site name and contact details on the Contact Tab are also linked and should only be edited via the Odoo interface.

A Patriot client is linked to a single Odoo customer
Typically a single Patriot dealer/installer will be linked to a single Odoo customer (of Patriot Dealer type).

When you open the Details tab of a Patriot dealer that is linked to an Odoo customer, the Odoo customer is displayed in the Accounting Integration section. You can quickly open the linked customer in the Odoo web interface by clicking the web link button.

A Patriot dealer is linked to a single Odoo customer
One or more Patriot client[s] can be linked to a single Odoo customer.

Patriot's Master Charges should be linked to Odoo products. This is not required but it is useful for running sales reports etc. within Odoo. To link a Patriot master charge to an Odoo product first open Master Charges from the Patriot Billing menu. Next select a master charge and use the Odoo Product selector to search for and set the matching product setup in Odoo. The Odoo product must be setup in Odoo, in advance, from the Sales -> Products menu. After you have linked a charge to an Odoo product you still need to make sure that the value amount is set correctly in the Patriot master charge and any client/dealer charge overrides. This is because Patriot is responsible for initiating billing batch runs and this is the amount used by Patriot when calculating its internal control totals (Patriot does not take the Odoo product price into account).

Note: Patriot does not automatically keep master charges in sync. with their linked Odoo products.

Odoo products are linked to Patriot Master Charges
Odoo products are linked to Patriot Master Charges.

Using Odoo with Patriot

Customer Maintenance

New Patriot clients can be inserted from Odoo: insert a new Odoo customer and choose a client Patriot Type, the Patriot tab will appear at bottom right, open this tab then check "Insert Patriot Client". Now when you save the Odoo customer a new matching client will be inserted in Patriot, and a link will be setup between the name and contact information fields stored both databases.

Odoo customers are kept in sync. with linked Patriot client[s]
Odoo customer's are kept in sync. with their linked Patriot client[s].

Patriot dealer's cannot be inserted from Odoo, but they can be linked retrospectively, once the dealer has been manually inserted in Patriot and Odoo. Linking a Patriot dealer to and Odoo dealer customer must be done from the dealer maintenance tool in Patriot on the dealer's Details tab. When you open the Patriot tab of a linked dealer customer in Odoo your will see a list of all Patriot clients belonging to the dealer.

Odoo dealer customers display assigned clients on the Patriot tab.
Odoo dealer customers display their assigned Patriot clients on the Patriot tab.

Invoicing

Patriot can send billing data to the Odoo invoicing system periodically using it's billing batch system. Patriot support will supply you with a set of Odoo specific billing batch runs for import upon installing the module. This set will include batch runs for Service (direct client billing and via dealer billing), Activation and Work Order billing. After a periodic billing batch run completes in Patriot, you can view the invoices in Odoo in the Customer Invoices section of the Odoo Accounting module. The Odoo invoice includes a link back to the raw billing data in Patriot on the "Other Info" tab. This allows you to quickly locate in Patriot the client, activation[s] or workorder[s] which have been billed in the invoice.

Odoo Invoice
Work order invoice generated by Odoo after being sent from Patriot by a periodic work order billing batch run.

Odoo Invoice
On the "Other Info" tab of the Odoo invoice there is a button link to open the invoice's raw billing data back in Patriot.

Leads & Opportunities

Patriot operators can insert Leads (sales enquires from existing customers) and Opportunities (sales enquires from potential customers) directly into the Odoo customer relationship management (CRM) module.

Leads are inserted by opening the Patriot client for whom the lead originated, and then using the client log note pin at top right of the screen to fill in a new log note with details about the sales lead. Check the "Log To CRM" box, select an action by date, and then save to send the lead to the Odoo CRM.

Inserting a lead from Patriot
A lead being inserted into the Odoo CRM from within Patriot.

Opportunities represent sales enquires from new potential customers, in this case there will be no client account in Patriot, so to log a new sales opportunity to the Odoo CRM open the Messages log book tool from the main Monitoring menu. Insert a new message and check the "Log to CRM" box. A form will appear where you can enter contact details which will be sent to the Odoo CRM pipeline along with the opportunity description and notes when the save button is pressed.

Inserting an opportunity from Patriot
An opportunity being inserted into the Odoo CRM from within Patriot.

In Odoo, Leads and Opportunities sent from Patriot enter the CRM pipeline at the first (new) stage. You can open your CRM pipeline via the main Sales menu in Odoo. Please refer to Odoo CRM documentation or ask your Odoo software integrator for further information about using the sales pipeline, details of which are beyond the scope of this document.

Odoo CRM Pipeline
Leads and Opportunities from Patriot enter the Odoo CRM sales pipeline.