Odoo Community Association

TMS Document

Alpha License: AGPL-3 OCA/stock-logistics-transport Translate me on Weblate Try me on Runboat

Generic, expiry-tracked document framework for the TMS.

Attach typed documents (license, insurance, inspection, …) to any TMS resource (drivers, vehicles). Document validity (valid / expiring / expired) is computed from the expiry date against a configurable horizon.

A document can be flagged critical: an expired critical document on a trip’s driver or vehicle blocks starting that trip.

Important

This is an alpha version, the data model and design can change at any time without warning. Only for development or testing purpose, do not use in production. More details on development status

Table of contents

Configuration

The expiry horizon is controlled by the configuration parameter tms.document.expiry_horizon_days (default: 30 days).

A document whose expiry date is within this many days is considered expiring; once the expiry date passes, it is expired.

To change the horizon, set the parameter under Settings > Technical > Parameters (or via ir.config_parameter.set_param). A smaller value makes documents switch to expiring later; a larger value warns earlier.

Usage

Creating a document

Documents can be created from the Documents menu under TMS > Documents, or directly from a driver or vehicle form using the Documents tab. Click Create and fill in:

  • Document type: e.g. driver license, vehicle insurance, inspection.
  • Number / reference: the reference printed on the document.
  • Holder: the TMS resource the document belongs to (a driver or a vehicle).
  • Expiry date: used to compute the validity state.
  • Critical: mark the document as critical to enforce it on trip start.

When uploading a file from the Documents tab of a holder form, the document is automatically linked to that holder and the file is attached to the holder’s chatter.

Once saved, the document appears read-only in the Documents tab of its holder’s form, so all documents of a driver or vehicle are visible in one place.

Validity states

The document state is computed from its expiry date and the configured horizon (see Configure):

  • Valid — the expiry date is further away than the horizon.
  • Expiring — the expiry date falls within the horizon.
  • Expired — the expiry date is in the past.

Blocking trip start

When a trip is started, all documents of its driver and vehicle are checked. If any critical document is expired, a user error is raised and the trip cannot be started until the document is renewed, its expiry date is corrected, or it is no longer flagged critical.

Bug Tracker

Bugs are tracked on GitHub Issues. In case of trouble, please check there if your issue has already been reported. If you spotted it first, help us to smash it by providing a detailed and welcomed feedback.

Do not contact contributors directly about support or help with technical issues.

Credits

Authors

  • Volkan Taşçı

Other credits

  • VSL
  • Odoo Community Association (OCA)

Maintainers

This module is maintained by the OCA.

Odoo Community Association

OCA, or the Odoo Community Association, is a nonprofit organization whose mission is to support the collaborative development of Odoo features and promote its widespread use.

Current maintainer:

volkantasci

This module is part of the OCA/stock-logistics-transport project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.