[IMP] hr_holidays: improved 'this year' button on search view of holidays.

bzr revid: qdp-launchpad@openerp.com-20120326132557-nuyevng79oe5oham
This commit is contained in:
Quentin (OpenERP)
2012-03-26 15:25:57 +02:00
parent d11b9c7868
commit 397cdef40f
+1 -1
View File
@@ -12,7 +12,7 @@
<filter icon="terp-camera_test" domain="[('state','=','confirm')]" string="To Approve" name="approve"/>
<filter icon="terp-camera_test" domain="[('state','=','validate')]" string="Validated" name="validated"/>
<separator orientation="vertical"/>
<filter icon="terp-go-year" name="year" string="Year" domain="[('date_from','&gt;=',time.strftime('%%Y-1-1')),('date_from','&lt;=',time.strftime('%%Y-12-31'))]"/>
<filter icon="terp-go-year" name="year" string="Year" domain="[('holiday_status_id.active','=',True)" help="Filters only on allocations and requests that belong to an holiday type that is 'active' (active field is True)"/>
<filter icon="terp-go-month" name="This Month" string="Month" domain="[('date_from','&lt;=',(datetime.date.today()+relativedelta(day=31)).strftime('%%Y-%%m-%%d')),('date_from','&gt;=',(datetime.date.today()-relativedelta(day=1)).strftime('%%Y-%%m-%%d'))]"/>
<filter icon="terp-go-month" name="This Month-1" string=" Month-1"
domain="[('date_from','&lt;=', (datetime.date.today() - relativedelta(day=31, months=1)).strftime('%%Y-%%m-%%d')),('date_from','&gt;=',(datetime.date.today() - relativedelta(day=1,months=1)).strftime('%%Y-%%m-%%d'))]"