Odoo. Approved by IT Libertas. Special Issue

Showing Odoo objects on maps by PostGIS tools and Geospatial modules' set

IT Libertas, Aleksandr Filippov

The following apps have been tested and have been approved by IT Libertas developers, in order to help you use Odoo. When programmers had faced any bugs, they fixed them. The resulted modules are structured and would be used as a base of Odoo implementation. Besides, each description contains links to download an application and to configure it with your own hands

The Odoo Geospatial set consists of 7 modules. Their aim is to implement PostGIS in Odoo and to provide an API. For Odoo users the most interesting in the set are obviously the tools to display various Odoo objects on a map. 

Thus, the modules geoengine_partner and geoengine_base_geolocalize allows localizing a customer or a supplier by addresses.

Geospatial for projects (geoengine_project) provides a tool to do the same with projects and apply filters to them.

Finally, Geospatial for sale (geoengine_sale) is to work with orders and to visually compare various indicators right on a map.

All the apps were tested on the Odoo 8 and may be downloaded here

Odoo partners on a map

The 2 mutually dependent modules geoengine partner and geoengine base geolocalize provide with a neat set of functions. To start with, we get a map and a button on a partner form. The button allows displaying a supplier, a customer, a carrier, even a user (basically, any partner) on a map based on values in the address fields.

Another key feature is an additional type of view for partners. You would find a special icon at the usual kanban-tree-form stack. This view mode provides possibilities:

  • To display all partners on a single map 

  • To filter partners on a map

  • To show customers' info at related locations

Consider also the app geoengine_geoname_geocoder to process automatic partners' geocoding. This app represents a special service, which uses Geonames and requires a sign up there. Be cautious: we faced a few difficulties in attempts to use it.

Project management and maps

Keep enumerating Geospatial tools for partners, we should emphasize that a similar functionality is provided for Odoo projects. Generally, project geo coordinates depend on a project's customer. Hence, everything possible for partners is possible for projects. Thus:

  • Find straight-line distance between 2 Odoo partners or projects on a map

  • Find a length of a complex route between locations

  • Measure an area of the shape on the map

Sales geo analysis

As in case of projects, Odoo sale orders' and quotations' locations depend on a stated customer and, certainly, have similar possibilities.

In comparison to previously stated modules, the only additional feature is a tool to gauge orders by an amounts' ratio. The bigger is total sum, the bigger is an area of a related map circle.

For developers only: geospatial core

Base_geoengine is all the stated modules' core, which supports geospatial data inside Odoo. The app introduces a few field's and view's types. Field's types are:
  • GeoField — metatype for geotypes;

  • GeoLine — simple straight line on two points;

  • GeoMultiLine — complex line with multiple points;

  • GeoMultiPoint — an array of geo points;

  • GeoMultiPolygon — an array of geo polygons;

  • GeoPoint — simple point;

  • GeoPolygon — polygon on multiple points.

View's types are:
  • geoengine.vector.layer — view for vector geoform drawing;

  • geoengine.raster.layer — view for raster geoform drawing.

 If you are going to develop your own tools related to maps, you should rely exactly on this functionality. Do not forget to read the documentation!