Skip to Content
Menu
This question has been flagged
Hello, I need to know how to delete a record automatically according to a condition.


Avatar
Discard
Best Answer

In Odoo 16

You need to create automated action

By using odoo interface

  1. Activate developer mode
  2. Go to settings -> Automation -> Automated actions
  3. Click create
  4. Choose a model where you want apply on the action
  5. Choose a trigger for example on form modification
  6. In field Action To Do, choose Execute python code
  7. In the Python code textarea, write action = your_record.unlik()

Note that your_record should be the records data you want to delete

You can also check server actions 

Avatar
Discard
Related Posts Replies Views Activity
0
Nov 23
979
1
Aug 24
1528
1
Nov 23
4031
3
Nov 24
10251
1
Jun 21
2640