Files
Odoo-18.0-20251222/web_timeline/models/ir_ui_view.py
tocmo0nlord adbe430761
Some checks failed
pre-commit / pre-commit (push) Has been cancelled
tests / Detect unreleased dependencies (push) Has been cancelled
tests / test with OCB (push) Has been cancelled
tests / test with Odoo (push) Has been cancelled
Initial commit: Odoo 18.0-20251222 extra-addons
2026-03-13 20:43:25 +00:00

20 lines
602 B
Python
Executable File

# Copyright 2016 ACSONE SA/NV (<http://acsone.eu>)
# Copyright 2024 Tecnativa - Carlos Lopez
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html).
from odoo import fields, models
TIMELINE_VIEW = ("timeline", "Timeline")
class IrUIView(models.Model):
_inherit = "ir.ui.view"
type = fields.Selection(selection_add=[TIMELINE_VIEW])
def _is_qweb_based_view(self, view_type):
return view_type == TIMELINE_VIEW[0] or super()._is_qweb_based_view(view_type)
def _get_view_info(self):
return {"timeline": {"icon": "fa fa-tasks"}} | super()._get_view_info()