| Availability |
Odoo Online
Odoo.sh
On Premise
|
| Lines of code | 806 |
| Technical Name |
gb_field_level_change_history_audit_log |
| License | OPL-1 |
| Website | https://gencbaris.com/odoo_plugins/ |
| Versions | 18.0 19.0 |
| Availability |
Odoo Online
Odoo.sh
On Premise
|
| Lines of code | 806 |
| Technical Name |
gb_field_level_change_history_audit_log |
| License | OPL-1 |
| Website | https://gencbaris.com/odoo_plugins/ |
| Versions | 18.0 19.0 |
Field-Level Change Histor
Track who changed which fields on any model, with full history and one-click revert
When a price, a status or a piece of master data changes and nobody knows who did it or what it was before, you have a compliance and trust gap that Odoo's chatter only partly fills. This module records every change on exactly the models and fields you choose — old value, new value, user and timestamp — in a searchable, retention-managed audit.log. Setup is self-service through audit.rule records, with no developer needed to turn tracking on. Crucially, any write change can be reverted from the log with one click (and the revert is itself audited), so the trail doubles as a recovery tool. Built-in activity reports, per-record timelines and a cron-based retention policy keep it useful for finance, IT and compliance teams that need accountability over critical data.
Key Features
Self-service audit rules per model and field
An audit.rule record points at any ir.model and a Many2many of ir.model.fields to watch; leave the field list empty and _tracked_field_names auto-selects every stored, non-computed field. Admins switch tracking on from the UI with no developer involved.
Captures create, write and unlink
An AbstractModel inheriting base hooks create, write and unlink, so every watched model is covered automatically. Per-rule log_create, log_write and log_unlink flags let you record only the operations you care about, with the pre-write value captured before super() runs.
Old and new value on every change
Each audit.log entry stores old_value_display, new_value_display plus the raw values, the field label and field type. Writes that don't actually change the value are skipped, so the log stays free of noise.
Human-readable values, not raw IDs
_audit_display resolves Many2one targets to their display_name and selection keys to their translated labels. Reviewers read 'Draft to Posted' or a partner name instead of cryptic IDs and technical codes.
One-click revert with audit of the revert
action_revert on a write entry coerces the stored old raw value back to the field's type and writes it to the live record, then marks the entry reverted. A computed can_revert gates this to supported field types, turning the log into a safe recovery tool.
Bulk revert wizard
audit.revert.wizard takes the entries selected in the log and, with restore_latest_only, groups them by (model, record, field) so a field is rolled back once to its prior value rather than chained step by step. It reports how many were restored and how many were skipped.
Activity report and per-record timeline
audit.report.wizard groups changes by model and operation over a date range with optional model/user filters, producing summary lines and a drill-down to matching entries. get_record_timeline and summarize_user_activity expose ordered history and per-user counts.
Retention cron and system-user noise control
Each rule has a retention_days value; the _cron_prune_logs scheduled job deletes audit.log rows older than that cutoff (0 keeps them forever). ignore_system_user drops changes made by base.user_root, and core technical models are excluded to prevent recursion.
Use Cases
Screenshots
Audit Rules
Why Choose This Module
When a price, a status or a key field changes and no one knows who did it or what it was before, you have a compliance and trust problem. This module records every change on the models and fields you choose — the old value, the new value, the user and the timestamp — in a searchable, prunable audit log. Each change can be reverted from the log with one click, and the revert is audited too. No developer needed to turn it on.
Specifications
- Compatible: Odoo 18.0 / 19.0
- License: LGPL-3
- Languages: 35+
- Author: Baris Genc
- Dependencies: base
- Support: odoo@gencbaris.com
Odoo Proprietary License v1.0 This software and associated files (the "Software") may only be used (executed, modified, executed after modifications) if you have purchased a valid license from the authors, typically via Odoo Apps, or if you have received a written agreement from the authors of the Software (see the COPYRIGHT file). You may develop Odoo modules that use the Software as a library (typically by depending on it, importing it and using its resources), but without copying any source code or material from the Software. You may distribute those modules under the license of your choice, provided that this license is compatible with the terms of the Odoo Proprietary License (For example: LGPL, MIT, or proprietary licenses similar to this one). It is forbidden to publish, distribute, sublicense, or sell copies of the Software or modified copies of the Software. The above copyright notice and this permission notice must be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Please log in to comment on this module