Skip to Content
Restrict Form Autosave
cst_restrict_auto_save_form

Restrict Form Autosave

Ask the user before saving when leaving a modified form.

  • Odoo 18
  • Tools & Administration
  • 18.0.1.0.0
1

Overview

By default the web client saves modified forms silently when you navigate away. This module patches the form controller so leaving a dirty record opens a dialog asking whether to save the changes. The same confirmation applies when paging between records. It helps every backend user avoid accidental saves.

2

Usage steps

  1. 1

    Detect unsaved changes

    When the user tries to leave a form the controller checks whether the record is dirty. Clean records leave normally.

    • beforeLeave hook
    • Only dirty records prompt
  2. 2

    Show the save dialog

    A confirmation dialog asks whether to save your changes. The user chooses to save, discard or stay.

    • Save
    • Discard
    • Stay on form
  3. 3

    Guard record paging

    Using the pager to move to another record triggers the same check. Navigation is cancelled if the user does not confirm.

    • onPagerUpdate override
    • Cancel keeps current record
  4. 4

    Applies everywhere

    Because it patches the shared form controller it applies to all form views without configuration. No menus or settings are added.

    • No configuration
    • Web client asset only
4

Roles

Benefiting roles
Role
All backend users
5

Dependencies

Back to version applications

Want to know more or try this app? Contact us

We can arrange a demo or a trial and answer your questions about Restrict Form Autosave.

Contact us