1
<?xml version="1.0" encoding="utf-8"?>
4
<record id="view_hr_holidays_report_tree" model="ir.ui.view">
5
<field name="name">hr.holidays.report.tree</field>
6
<field name="model">hr.holidays.report</field>
7
<field name="type">tree</field>
8
<field name="arch" type="xml">
9
<tree string="Leaves Statistics">
11
<field name="employee_id"/>
12
<field name="date_from"/>
13
<field name="date_to"/>
14
<field name="number_of_days_temp"/>
15
<field name="year" invisible="1"/>
16
<field name="month" invisible="1"/>
22
<record id="view_hr_holidays_report_graph" model="ir.ui.view">
23
<field name="name">hr.holidays.report.graph</field>
24
<field name="model">hr.holidays.report</field>
25
<field name="type">graph</field>
26
<field name="arch" type="xml">
27
<graph string="Leaves Statistics" type="bar">
28
<field name="employee_id"/>
29
<field name="number_of_days_temp" operator="+"/>
34
<record id="view_hr_holidays_report_search" model="ir.ui.view">
35
<field name="name">hr.holidays.report.search</field>
36
<field name="model">hr.holidays.report</field>
37
<field name="type">search</field>
38
<field name="arch" type="xml">
39
<search string="Leaves">
40
<filter icon="terp-hr"
42
domain="[('year','=',time.strftime('%%Y'))]"
43
help="Leaves of the year"/>
44
<filter icon="terp-hr"
46
domain="[('month','=',time.strftime('%%m'))]"
47
help="Leaves of this month"/>
48
<separator orientation="vertical"/>
49
<filter icon="terp-hr"
50
string="Today's Start Leave"
51
domain="[('date_from','=',time.strftime('%%Y/%%m/%%d'))]"/>
52
<filter icon="terp-hr"
53
string="Today's End Leave"
54
domain="[('date_to','=',time.strftime('%%Y/%%m/%%d'))]"/>
55
<separator orientation="vertical"/>
56
<field name="employee_id"/>
57
<field name="user_id" widget="selection">
58
<filter icon="terp-sale"
61
domain="[('user_id','=',uid)]"/>
64
<group expand="1" string="Group By..." colspan="10" col="12">
65
<filter string="Employee" icon="terp-hr" context="{'group_by':'employee_id'}"/>
66
<separator orientation="vertical"/>
67
<filter string="State" icon="terp-hr" context="{'group_by':'state'}"/>
68
<separator orientation="vertical"/>
69
<filter string="Month" icon="terp-sale" context="{'group_by':'date'}"/>
70
<filter string="Year" icon="terp-sale" context="{'group_by':'year'}"/>
76
<record id="action_hr_holidays_report_all" model="ir.actions.act_window">
77
<field name="name">Leaves</field>
78
<field name="res_model">hr.holidays.report</field>
79
<field name="view_type">form</field>
80
<field name="view_mode">tree,graph</field>
81
<field name="search_view_id" ref="view_hr_holidays_report_search"/>
84
<menuitem action="action_hr_holidays_report_all" id="menu_hr_holidays_report_all" parent="hr.menu_hr_reporting" sequence="0"/>