[6.0] how to define the default search buttons

Asked by Ferdinand

how to start a form with one ore more search view buttons pressed?

thanks

Question information

Language:
English Edit question
Status:
Answered
For:
Odoo Server (MOVED TO GITHUB) Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Denis Konchekov (dkonchekov) said :
#1

You can look at email_template_account_view.xml from email_template addon. In search form "draft" search button is pressed by default.
There is filter field in record with id = "view_email_template_account_search":
<filter icon="terp-document-new" string="Draft" name="draft" domain="[('state','=','draft')]"/>

And next, in record with id = "action_email_template_account_tree_all">
context field is defined:
<field name="context">{'group_by': [], 'search_default_draft': 1, 'search_default_my': 1}</field>.

Can you help with this problem?

Provide an answer of your own, or ask Ferdinand for more information if necessary.

To post a message you must log in.