Odoo is the world's easiest all-in-one management software. It includes hundreds of business apps:
CRM | e-Commerce | Accounting | Inventory | PoS | Project management | MRP | etc.
I have created Many2Many with:
Field type: res.partner
Here is the code inside lead/opportunity
<field name="x_entreprises" domain="[('customer','=',True)]" string=" ">
<tree string="Entreprises" editable="top">
Then I created One2Many with
Object relation: crm.lead
Relation field: x_entreprises
Here is the code inside res.partner
<field name="x_entreprises_ids" string=" " readonly="1" domain="[('id', 'in', x_entreprises)]">
<field name="planned_revenue" sum="total"/>
Inside that Many2Many field i am able to add company that take part on the opportunities. When I access the customer form, I should be able to see the opportunities that the customer is involved in.
The error: when I add more then 1 customer inside that many2many fields and then I go to that Customer form I will have singleton error (Expected singleton: res.partner(52350, 52353)). I believe my domain inside One2Many field is wrong.
Please let me know, how to solve this issue. Thank you so much.
About This Community
This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.Register
Odoo Training Center
Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.Test it now
|Asked: 9/5/15, 3:18 PM|
|Seen: 1660 times|
|Last updated: 9/16/15, 9:09 AM|