hr_timesheet/report/hr_timesheet_report_view.xml

190 lines
9.5 KiB
XML
Raw Permalink Normal View History

<?xml version="1.0" encoding="utf-8"?>
<odoo>
<data>
<record id="timesheets_analysis_report_pivot_employee" model="ir.ui.view">
<field name="name">timesheets.analysis.report.pivot</field>
<field name="model">timesheets.analysis.report</field>
<field name="arch" type="xml">
<pivot string="Timesheets Analysis" sample="1" disable_linking="True">
<field name="employee_id" type="row"/>
<field name="date" interval="month" type="col"/>
<field name="amount" string="Timesheet Costs"/>
<field name="unit_amount" type="measure" widget="timesheet_uom"/>
</pivot>
</field>
</record>
<record id="timesheets_analysis_report_graph_employee" model="ir.ui.view">
<field name="name">timesheets.analysis.report.graph</field>
<field name="model">timesheets.analysis.report</field>
<field name="arch" type="xml">
<graph string="Timesheets" sample="1" js_class="hr_timesheet_graphview" disable_linking="True">
<field name="employee_id" type="row"/>
<field name="amount" string="Timesheet Costs"/>
<field name="unit_amount" type="measure" widget="timesheet_uom"/>
</graph>
</field>
</record>
<record id="timesheets_analysis_report_pivot_project" model="ir.ui.view">
<field name="name">timesheets.analysis.report.pivot</field>
<field name="model">timesheets.analysis.report</field>
<field name="arch" type="xml">
<pivot string="Timesheets Analysis" sample="1" disable_linking="True">
<field name="project_id" type="row"/>
<field name="date" interval="month" type="col"/>
<field name="amount" string="Timesheet Costs"/>
<field name="unit_amount" type="measure" widget="timesheet_uom"/>
</pivot>
</field>
</record>
<record id="timesheets_analysis_report_graph_project" model="ir.ui.view">
<field name="name">timesheets.analysis.report.graph</field>
<field name="model">timesheets.analysis.report</field>
<field name="arch" type="xml">
<graph string="Timesheets" sample="1" js_class="hr_timesheet_graphview" disable_linking="True">
<field name="project_id" type="row"/>
<field name="amount" string="Timesheet Costs"/>
<field name="unit_amount" type="measure" widget="timesheet_uom"/>
</graph>
</field>
</record>
<record id="timesheets_analysis_report_pivot_task" model="ir.ui.view">
<field name="name">timesheets.analysis.report.pivot</field>
<field name="model">timesheets.analysis.report</field>
<field name="arch" type="xml">
<pivot string="Timesheets Analysis" sample="1" disable_linking="True">
<field name="amount" string="Timesheet Costs"/>
<field name="project_id" type="row"/>
<field name="task_id" type="row"/>
<field name="date" interval="month" type="col"/>
<field name="unit_amount" type="measure" widget="timesheet_uom"/>
</pivot>
</field>
</record>
<record id="timesheets_analysis_report_graph_task" model="ir.ui.view">
<field name="name">timesheets.analysis.report.graph</field>
<field name="model">timesheets.analysis.report</field>
<field name="arch" type="xml">
<graph string="Timesheets" sample="1" js_class="hr_timesheet_graphview" disable_linking="True">
<field name="project_id" type="row"/>
<field name="task_id" type="row"/>
<field name="amount" string="Timesheet Costs"/>
<field name="unit_amount" type="measure" widget="timesheet_uom"/>
</graph>
</field>
</record>
<record id="hr_timesheet_report_search" model="ir.ui.view">
<field name="name">timesheets.analysis.report.search</field>
<field name="model">timesheets.analysis.report</field>
<field name="inherit_id" ref="hr_timesheet.hr_timesheet_line_search"/>
<field name="mode">primary</field>
<field name="arch" type="xml">
<search position="attributes">
<attribute name="string">Timesheet Report</attribute>
</search>
</field>
</record>
<!-- Group by employee -->
<record id="act_hr_timesheet_report" model="ir.actions.act_window">
<field name="name">Timesheets by Employee</field>
<field name="res_model">timesheets.analysis.report</field>
<field name="domain">[('project_id', '!=', False)]</field>
<field name="context">{}</field>
<field name="search_view_id" ref="hr_timesheet_report_search"/>
<field name="view_mode">pivot,graph</field>
<field name="help" type="html">
<p class="o_view_nocontent_empty_folder">
No data yet!
</p><p>
Analyze the projects and tasks on which your employees spend their time.<br/>
Evaluate which part is billable and what costs it represents.
</p>
</field>
</record>
<record model="ir.actions.act_window.view" id="act_hr_timesheet_report_pivot">
<field name="sequence" eval="5"/>
<field name="view_mode">pivot</field>
<field name="view_id" ref="hr_timesheet.timesheets_analysis_report_pivot_employee"/>
<field name="act_window_id" ref="act_hr_timesheet_report"/>
</record>
<record id="timesheet_action_view_report_by_employee_graph" model="ir.actions.act_window.view">
<field name="sequence" eval="6"/>
<field name="view_mode">graph</field>
<field name="view_id" ref="hr_timesheet.timesheets_analysis_report_graph_employee"/>
<field name="act_window_id" ref="act_hr_timesheet_report"/>
</record>
<!-- Group by project-->
<record id="timesheet_action_report_by_project" model="ir.actions.act_window">
<field name="name">Timesheets by Project</field>
<field name="res_model">timesheets.analysis.report</field>
<field name="domain">[('project_id', '!=', False)]</field>
<field name="context">{}</field>
<field name="search_view_id" ref="hr_timesheet_report_search"/>
<field name="view_mode">pivot,graph</field>
<field name="help" type="html">
<p class="o_view_nocontent_empty_folder">
No data yet!
</p><p>
Analyze the projects and tasks on which your employees spend their time.<br/>
Evaluate which part is billable and what costs it represents.
</p>
</field>
</record>
<record id="timesheet_action_view_report_by_project_pivot" model="ir.actions.act_window.view">
<field name="sequence" eval="5"/>
<field name="view_mode">pivot</field>
<field name="view_id" ref="hr_timesheet.timesheets_analysis_report_pivot_project"/>
<field name="act_window_id" ref="timesheet_action_report_by_project"/>
</record>
<record id="timesheet_action_view_report_by_project_graph" model="ir.actions.act_window.view">
<field name="sequence" eval="6"/>
<field name="view_mode">graph</field>
<field name="view_id" ref="hr_timesheet.timesheets_analysis_report_graph_project"/>
<field name="act_window_id" ref="timesheet_action_report_by_project"/>
</record>
<!-- Group by task -->
<record id="timesheet_action_report_by_task" model="ir.actions.act_window">
<field name="name">Timesheets by Task</field>
<field name="res_model">timesheets.analysis.report</field>
<field name="domain">[('project_id', '!=', False)]</field>
<field name="context">{}</field>
<field name="search_view_id" ref="hr_timesheet_report_search"/>
<field name="view_mode">pivot,graph</field>
<field name="help" type="html">
<p class="o_view_nocontent_empty_folder">
No data yet!
</p><p>
Analyze the projects and tasks on which your employees spend their time.<br/>
Evaluate which part is billable and what costs it represents.
</p>
</field>
</record>
<record id="timesheet_action_view_report_by_task_pivot" model="ir.actions.act_window.view">
<field name="sequence" eval="5"/>
<field name="view_mode">pivot</field>
<field name="view_id" ref="hr_timesheet.timesheets_analysis_report_pivot_task"/>
<field name="act_window_id" ref="timesheet_action_report_by_task"/>
</record>
<record id="timesheet_action_view_report_by_task_graph" model="ir.actions.act_window.view">
<field name="sequence" eval="6"/>
<field name="view_mode">graph</field>
<field name="view_id" ref="hr_timesheet.timesheets_analysis_report_graph_task"/>
<field name="act_window_id" ref="timesheet_action_report_by_task"/>
</record>
</data>
</odoo>