Properties should be deleted when the related record is deleted
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Odoo Server (MOVED TO GITHUB) |
Fix Released
|
Medium
|
OpenERP's Framework R&D |
Bug Description
Hello,
I constated the following bug:
- Create a new partner
- Create two financial accounts
- Set this accounts as account receivable and account payable
- Delete the partner
- Try to delete an account
An error appear: we cannot delete account that is linked to a partner. But the partner has been deleted.
This bug come because the accounts payable and receivable in the object partner is not a fields.many2one, bug a fields.property (I don't understant why), and the property in the table ir_property stay when we delete a partner.
The best solution to correct this bug would be to set the fields accounts in partner as one2many type instead of property.
I use OpenERP 6.0.3 on a Ubuntu 10.04LTS server.
Thanks
Related branches
- OpenERP Core Team: Pending requested
-
Diff: 25 lines (+8/-0)1 file modifiedaccount/partner.py (+8/-0)
- OpenERP R&D Team: Pending requested
- Vo Minh Thu: Pending requested
- Olivier Dony (Odoo): Pending requested
-
Diff: 25 lines (+8/-2)1 file modifiedopenerp/osv/orm.py (+8/-2)
Changed in openobject-addons: | |
assignee: | nobody → OpenERP R&D Addons Team 3 (openerp-dev-addons3) |
importance: | Undecided → Medium |
status: | New → Confirmed |
Changed in openobject-addons: | |
status: | Confirmed → In Progress |
affects: | openobject-addons → openobject-server |
Changed in openobject-server: | |
assignee: | OpenERP R&D Addons Team 3 (openerp-dev-addons3) → OpenERP's Framework R&D (openerp-dev-framework) |
summary: |
- Cannot remove account linked to a deleted partner + Properties should be deleted when the related record is deleted |
Hello Damien,
Thanks for reporting. The solution for this bug is proposed in the branch : https:/ /code.launchpad .net/~openerp- dev/openobject- addons/ trunk-bug- 891580- mdi/
with following Revision ID and Number.
Revision ID : <email address hidden>
Revision Number : 5744
Thanks and Regards,
Divyesh Makwana(MDI)