Define a new view displaying events in an interactive visualization chart.
The widget is based on the external library
auto_awesome What this module does
AI-generated from the code · Odoo 19.0Adds a new Timeline view to Odoo that shows records as an interactive time chart, grouped by a field, with zoom levels (day, week, month, year) and drag-and-drop editing.
This module adds a new kind of view, called Timeline, that any Odoo screen can use to display records on a horizontal time axis. Each record appears as a bar or point placed at its start date, optionally ending at a stop date or extended by a delay in hours.
- Records are grouped into rows by a chosen field (for example a user, a project or a status), and a row called UNASSIGNED collects records without a group.
- Buttons above the chart let users jump to Today and switch the scale between Day, Week, Month and Year; the chart can also fit all data in the window.
- If the user has write rights, items can be dragged to change their dates or moved to another group; if they have create rights, new items can be added directly on the chart; if they have delete rights, items can be removed after a confirmation message.
- Clicking a group opens the related record in a form; double-clicking an item opens it in a form, either in a popup or by switching to the form view, depending on the view settings.
- Colours can be assigned to items through conditions defined in the view, and optional arrows can be drawn between items that depend on each other.
- The view respects the usual search bar, filters and grouping, and it checks the user's create, edit and delete permissions before enabling those actions.
Technically it extends ir.ui.view and ir.actions.act_window.view so that 'timeline' becomes a selectable view type, and it ships a demo timeline view for scheduled actions (ir.cron).
Depends on
Required by other modules
Models and fields (2)
- ir.ui.view · extends an existing modeltype
- ir.actions.act_window.view · extends an existing modelview_mode
Text generated by AI (DeepSeek) from reading the Odoo 19.0 code on GitHub; it may contain mistakes, so check the code before deciding. The module is very large and only part of the code was read. View the code on GitHub
Availability by version
Reviewed: 2026-11-03Confirmation status: 8 confirmed, 1 with no information of 9 versions.
Sources · Odoo 15.0
Confirmed on 2026-11-03 in branch 15.0 of OCA/web.
terminal Installation and usage
OCA documentation · Odoo 19.0Configuration
Source · Odoo 19.0You need to define a view with the tag \ as base element. These are the possible attributes for the tag:
| Attribute | Required? | Description | |----|----|----| | date_start | Yes | Defines the name of the field of type date that contains the start of the event. | | date_stop | No | Defines the name of the field of type date that contains the end of the event. The date_stop can be equal to the attribute date_start to display events has 'point' on the Timeline (instantaneous event). | | date_delay | No | Defines the name of the field of type float/integer that contain the duration in hours of the event, default = 1. | | default_group_by | Yes | Defines the name of the field that will be taken as default group by when accessing the view or when no other group by is selected. | | zoomKey | No | Specifies whether the Timeline is only zoomed when an additional key is down. Available values are '' (does not apply), 'altKey', 'ctrlKey', or 'metaKey'. Set this option if you want to be able to use the scroll to navigate vertically on views with a lot of events. | | mode | No | Specifies the initial visible window. Available values are: 'day' to display the current day, 'week', 'month' and 'fit'. Default value is 'fit' to adjust the visible window such that it fits all items. | | margin | No | Specifies the margins around the items. It should respect the JSON format. For example '{"item":{"horizontal":-10}}'. Available values are: '{"axis":\}' (The minimal margin in pixels between items and the time axis) '{"item":\}' (The minimal margin in pixels between items in both horizontal and vertical direction), '{"item":{"horizontal":\}}' (The minimal horizontal margin in pixels between items), '{"item":{"vertical":\}}' (The minimal vertical margin in pixels between items), '{"item":{"horizontal":\,"vertical":\}}' (Combination between horizontal and vertical margins in pixels between items). | | event_open_popup | No | When set to true, it allows to edit the events in a popup. If not (default value), the record is edited changing to form view. | | stack | No | When set to false, items will not be stacked on top of each other such that they do overlap. | | colors | No | Allows to set certain specific colors if the expressed condition (JS syntax) is met. | | dependency_arrow | No | Set this attribute to a x2many field to draw arrows between the records referenced in the x2many field. |
Optionally you can declare a custom template, which will be used to render the timeline items. You have to name the template 'timeline-item'. These are the variables available in template rendering:
record: to access the fields values selected in the timeline definition.formatters: used to format values (see available functions in@web/views/fields/formatters).parsers: used to parse values (see available functions in@web/views/fields/parsers).
You also need to declare the view in an action window of the involved model.
See web_timeline/demo/ir_cron_view.xml for a very basic timeline view example added onto cron tasks.
More evolved example, from project_timeline:
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<record id="view_task_timeline" model="ir.ui.view">
<field name="model">project.task</field>
<field name="type">timeline</field>
<field name="arch" type="xml">
<timeline date_start="date_assign"
date_stop="date_end"
string="Tasks"
default_group_by="project_id"
event_open_popup="true"
colors="white: user_ids == []; #2ecb71: state == '1_done'; #ec7063: state == '1_canceled'"
dependency_arrow="depend_on_ids"
>
<field name="user_ids" />
<field name="allocated_hours" />
<templates>
<t t-name="timeline-item">
<div class="o_project_timeline_item">
<t t-foreach="record.user_ids" t-as="user" t-key="user.id">
<img
t-if="record.user_ids"
t-attf-src="/web/image/res.users/#{user}/image_128/16x16"
t-att-title="record.user"
width="16"
height="16"
class="mr8"
alt="User"
/>
</t>
<span name="display_name">
<t t-esc="record.display_name" />
</span>
<small
name="allocated_hours"
class="text-info ml4"
t-if="record.allocated_hours"
>
<t
t-out="formatters.get('float_time')(record.allocated_hours)"
/>
</small>
</div>
</t>
</templates>
</timeline>
</field>
</record>
<record id="project.action_view_task" model="ir.actions.act_window">
<field
name="view_mode"
>kanban,list,form,calendar,timeline,pivot,graph,activity</field>
</record>
</odoo>Usage
Source · Odoo 19.0For accessing the timeline view, you have to click on the button with the clock icon in the view switcher. The first time you access to it, the timeline window is zoomed to fit all the current elements, the same as when you perform a search, filter or group by operation.
You can use the mouse scroll to zoom in or out in the timeline, and click on any free area and drag for panning the view in that direction.
The records of your model will be shown as rectangles whose widths are the duration of the event according our definition. You can select them clicking on this rectangle. You can also use Ctrl or Shift keys for adding discrete or range selections. Selected records are hightlighted with a different color (but the difference will be more noticeable depending on the background color). Once selected, you can drag and move the selected records across the timeline.
When a record is selected, a red cross button appears on the upper left corner that allows to remove that record. This doesn't work for multiple records although they were selected.
Records are grouped in different blocks depending on the group by criteria selected (if none is specified, then the default group by is applied). Dragging a record from one block to another change the corresponding field to the value that represents the block. You can also click on the group name to edit the involved record directly.
Double-click on the record to edit it. Double-click in open area to create a new record with the group and start date linked to the area you clicked in. By holding the Ctrl key and dragging left to right, you can create a new record with the dragged start and end date.
No verified information in OCA: Installation.
Installation instructions, the distribution package, dependencies and configuration steps are not shown because they have not yet been verified in the module documentation for any version.
Data imported from GitHub: this sheet reflects the latest catalog review, not a live lookup. Always check the module documentation and staging before installing in production.