I want to add a filter to group the timesheet tree by a custom field.
This is what I have:
< record id="hr_timesheet_line_my_timesheet_search_ext" model="ir.ui.view">
< field name="name">view.search.my.timesheet.menu.ext< /field>
< field name="model">account.analytic.line< /field>
< field name="inherit_id" ref="hr_timesheet.hr_timesheet_line_my_timesheet_search"/>
< field name="arch" type="xml">
< search string="Timesheet">
< group expand="0" string="Group By">
< filter name="group_by_custom_field" string="Custom Field" icon="terp-partner" context="{'group_by':'custom_field'}"/>
< /group>
< /search>
< /field>
< /record>
But the custom field is not showing in the groupby dropdown.
Thank you