Odoo Help

Welcome!

This community 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.

0

context value is not passed to the wizard in many2many

By
K Santosh Subba Rao
on 6/25/14, 5:48 PM 984 views

 <field name="search_matches" nolabel="1" widget="many2many_list" context="{'new_id':id}">
                                 <tree version="7.0" editable="bottom">
                                     <field name="user_id"/>
                                     <field name="stock_type"/>
                                     <field name="structure_building"/>
                                     <field name="property_vaastu"/>
                                     <button string="Schedule/Log Call"
                                name="%(opportunity2phonecall_act)d"
                                type="action"/>
                                 </tree>
                            </field>        
        when i click the button the context value is not passed to the wizard               

1

Vasiliy Birukov

--Vasiliy Birukov--
3446
| 6 6 8
Russian Federation
--Vasiliy Birukov--

Help develop and implement any project on base Odoo.

Vasiliy Birukov
On 6/26/14, 3:16 AM

Use active_id instead id

0
K Santosh Subba Rao
On 6/26/14, 7:32 AM

Thank you people,

The error was in my .py code

0

Jagdish Panchal

--Jagdish Panchal--
2674
| 5 3 6
Gandhinagar, India
--Jagdish Panchal--

OpenERP Developer

Jagdish Panchal
On 6/26/14, 3:23 AM

Hi

Try this code

 

                            <field name="search_matches" nolabel="1" widget="many2many_list">
                                 <tree version="7.0" editable="bottom">
                                     <field name="user_id"/>
                                     <field name="stock_type"/>
                                     <field name="structure_building"/>
                                     <field name="property_vaastu"/>
                                     <button name="%(opportunity2phonecall_act)d"  type="action"  string="Schedule/Log Call" context="{'new_id': active_id}"/>
                                 </tree>
                            </field>    

 

Your Answer

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

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)

Stats

Asked: 6/25/14, 5:48 PM
Seen: 984 times
Last updated: 3/16/15, 8:10 AM