I have created one2many field for selecting products, i click search more option it is showing the tree view, for this i need to select multiple products at a time in this tree view(one2many). is it possible in one2many field?
Can you provide me any suggestions.
Thanks in advance.
Assuming you have created a lines for an object, now those lines are defined in the List/Tree View.
Suppose if you created a field for Product say (many2one), then yes it will show you list of products from which you can select only one at a time.
So instead change the datatype of the product to Many2Many.
Object A (parent)
lines = fields.One2Many(ObjectB)
Object B (child)
product_ids = fields.Many2Many(product.product)
This way it will let add multiple products into your lines (one2many lines). Hope this helps you
Although the question is quite old, but still I am answering it for those who are still searching for the solution:
You can use this module to add checkboxes and a button to perform and action on selected records for x2many fields tree view:
Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!
About This Community
|Asked: 11/4/14, 3:16 AM|
|Seen: 2118 times|
|Last updated: 9/17/16, 3:40 AM|