Contributors mailing list archives
contributors@odoo-community.org
Browse archives
Odoo 9 Invoice Control Improvement Proposition
Prototyping Odoo PosBox with regular hardware we see in supermarkets daily
Prevent to delete product imported by a module
by
Akretion France., David BEAL
Hi all,
I need a generic way to prevent the user to delete product or any other record created by a module.What are the best options ?
I suggest:
- a base module
- which override unlink() by monkey patching
- check if in this record a boolean field named 'protected' or other convention exist and is True
- a base module
- which override unlink() by monkey patching
- check if in this record a boolean field named 'protected' or other convention exist and is True
- then prevent unlink
What do you think ?
Thanks for your suggestions
David BEAL - Akretion
Odoo Development / Integration
Follow-Ups
-
Re: Prevent to delete product imported by a module
byAkretion France., David BEAL- 20/05/2016 15:44:47 - 0 -
Re: Prevent to delete product imported by a module
bySYLEAM SARL, Sylvain Garancher- 19/05/2016 16:22:04 - 0 -
Re: Prevent to delete product imported by a module
byVauxoo, Moisés López Calderón- 19/05/2016 15:31:10 - 0 -
Re: Prevent to delete product imported by a module
byElico Corp, Eric Caudal- 19/05/2016 13:00:40 - 0 -
Re: Prevent to delete product imported by a module
byClosingAp Open Source Integrators Europe, LDA., Daniel Reis- 19/05/2016 12:56:21 - 0 -