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 want to create a button to call a wizard
1 How can I put it on the top of the tree view?
I tried: <field name="default_code" position="before">
<button name="%(split_into)d" string="Testing" type="action"/>
but then the button repeat every line but not on the top
2 Can I press a button to popup a screen when creating a record without saving the record?
I put the button inside the form but when I click it, the record will be saved before popup a new screen.
Can I popup a new screen without doing any action to the form?
1. I think you mean in the "more" options? If you do, try using the action record in the XML view pointing to your wizard. The model element in your <action> will be the reference to which object it will be attached to. For example: <field name="model">account.invoice</field> will put your action on the More button above the invoice tree view.
2. In the same action, use the element "target" and set its value to new. This will allow your wizard to open in a pop-up alike screen without alterting the form view. This can even be done in the 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
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: 11/12/14, 4:52 AM|
|Seen: 511 times|
|Last updated: 3/16/15, 8:10 AM|