<field name="account_id"/>
<field name="product_id"/>
</group>
+ <group expand="1" string="Group By...">
+ <filter string="User" name="User" icon="terp-hr" context="{'group_by':'user_id'}"/>
+ <separator orientation="vertical"/>
+ <filter string="Account" icon="terp-hr" context="{'group_by':'account_id'}"/>
+ <filter string="Product" icon="terp-hr" context="{'group_by':'product_id'}"/>
+ <filter string="Invoice" icon="terp-hr" context="{'group_by':'invoice_id'}"/>
+ <separator orientation="vertical"/>
+ <filter string="Day" icon="terp-hr" context="{'group_by':'day'}"/>
+ <filter string="Month" icon="terp-hr" context="{'group_by':'month'}"/>
+ <filter string="Year" icon="terp-hr" context="{'group_by':'name'}"/>
+ </group>
<newline/>
- <group expand="0" string="Extended filters..." groups="base.group_extended">
- <field name="date"/>
- <separator orientation="vertical"/>
- <field name="invoice_id" widget="selection"/>
+ <group expand="1" string="Group By..." colspan="10" col="12">
+ <filter string="User" name="User" icon="terp-hr" context="{'group_by':'user_id'}"/>
+ <separator orientation="vertical"/>
+ <filter string="Account" icon="terp-hr" context="{'group_by':'account_id'}"/>
+ <filter string="Product" icon="terp-hr" context="{'group_by':'product_id'}"/>
+ <filter string="Invoice" icon="terp-hr" context="{'group_by':'invoice_id'}"/>
+ <separator orientation="vertical"/>
+ <filter string="Day" icon="terp-hr" context="{'group_by':'day'}"/>
+ <filter string="Month" icon="terp-hr" context="{'group_by':'month'}"/>
+ <filter string="Year" icon="terp-hr" context="{'group_by':'name'}"/>
+ </group>
+ <newline/>
+ <group expand="0" string="Extended options..." colspan="10" col="12">
+ <field name="date"/>
+ <separator orientation="vertical"/>
+ <field name="invoice_id" widget="selection"/>
</group>
-
</search>
</field>
</record>
<field name="arch" type="xml">
<search string="Search Timesheet Lines">
<group col='15' colspan='4'>
- <field name="date"/>
+ <separator orientation="vertical"/>
+ <filter icon="terp-project" string="Current" default="1" domain="[('date','=',time.strftime('%%Y-%%m-%%d'))]"/>
+ <separator orientation="vertical"/>
<field name="user_id" widget="selection"/>
<field name="product_id" widget="selection"/>
- <field name="analytic_account_id" widget="selection"/>
- <field name="general_account_id" widget="selection"/>
</group>
<newline/>
- <group expand="1" string="Group By..." colspan="4" col="20">
+ <group expand="1" string="Group By...">
<filter string="User" icon="terp-project" domain="[]" context="{'group_by':'user_id'}"/>
<filter string="Product" icon="terp-project" domain="[]" context="{'group_by':'product_id'}"/>
<filter string="Analytic Account" icon="terp-project" domain="[]" context="{'group_by':'analytic_account_id'}"/>
help="Non Assigned Tasks to users"
domain="[('user_id','=',False)]"/>
</field>
- <field name="project_id" widget="selection">
+ <field name="project_id">
<filter icon="terp-project"
- string="Non assigned tasks to projects"
- help ="Non assigned tasks to projects"
- domain="[('project_id','=',False"/>
+ string="My Projects"
+ help="My Projects"
+ domain="[('project_id','=',context.get('project_id', False)]"/>
</field>
</group>
- <newline/>
- <group expand="0" string="Extended options..." colspan="10" col="12">
- <field name="type" widget="selection"/>
- <separator orientation="vertical"/>
- <field name="date_start"/>
- <field name="date_deadline"/>
- <separator orientation="vertical"/>
- <field name="priority"/>
- <field name="company_id" groups="base.group_multi_company" widget="selection"/>
- </group>
- <newline/>
<group expand="1" string="Group By..." colspan="10" col="11">
<filter string="User" name="User" icon="terp-project" context="{'group_by':'user_id'}" />
<filter string="Project" icon="terp-project" context="{'group_by':'project_id'}"/>