Repository
OCA/server-ux · module folder · Try on Runboat
Module version
1.0.0
Category
Tools
Folder size
0.06 MB
License
AGPL-3
Application
No
Auto-installable
No
Website
https://github.com/OCA/server-ux
Last tracking update
2026-08-07 09:06:24
Authors
Camptocamp, Akretion, Odoo Community Association (OCA), Agile Business Group, Serpent Consulting Services Pvt. Ltd., Ecosoft, Dreambits
Maintainers
Camptocamp, Akretion, Odoo Community Association (OCA), Agile Business Group, Serpent Consulting Services Pvt. Ltd., Ecosoft, Dreambits
Committers
Weblate, OCA-git-bot, oca-ci, Paula Marfull
Odoo dependencies
odoo/odoo:
Python dependencies
None
System dependencies
None
Required by
sale_order_revision
Description
Making revision(s) of a document is a common need across many area.

This module does not provide a functionality by itself but an abstract
model to implement revision capality in other models (e.g. purchase
orders, sales orders, budgets, expenses...).

**Note:** To be able to use this module in a new model you will need
some development.

See [sale_order_revision](https://github.com/OCA/sale-workflow) as an
example of implementation.

Example with sale_order_revision installed,

On a cancelled orders, you can click on the "New copy of Quotation"
button. This will create a new revision of the quotation, with the same
base number and a '-revno' suffix appended. A message is added in the
chatter saying that a new revision was created.

In the form view, a new tab is added that lists the previous revisions,
with the date they were made obsolete and the user who performed the
action.

The old revisions of a sale order are flagged as inactive, so they don't
clutter up searches.

**Special Remarks:** Starting on version 14, this module was splitted
from sale_order_revision to,

- base_revision
- sale_order_revision

Code Analysis

Views touched (0)

No views found for this module.

HTTP endpoints (0)

No HTTP endpoints found for this module.

Models touched (1)

New fields (7)
  • active Boolean
    default=True
  • current_revision_id Many2one → base.revision
    comodel_name='base.revision' copy=True readonly=True string='Current revision'
  • has_old_revisions Boolean
    compute='_compute_has_old_revisions'
  • old_revision_ids One2many → base.revision
    comodel_name='base.revision' context={'active_test': False} domain=['|', ('active', '=', False), ('active', '=', True)] inverse_name='current_revision_id' readonly=True string='Old revisions'
  • revision_count Integer
    compute='_compute_revision_count' string='Previous versions count'
  • revision_number Integer
    copy=False default=0 string='Revision'
  • unrevisioned_name Char
    copy=True readonly=True string='Original Reference'
Public methods (4)
  • copy(self, default=None)
  • copy_revision_with_context(self)
  • create(self, vals_list)
    @api.model_create_multi
  • create_revision(self)

Loading…

Loading…

Loading…

Loading…

Loading…