The loading order of the data files has to be modified, as this menuitem uses an action defined in hr_timesheet_sheet_data.xml.
57 lines
2.9 KiB
XML
57 lines
2.9 KiB
XML
<?xml version="1.0" ?>
|
|
<openerp>
|
|
<data noupdate="1">
|
|
<!-- notify all employees of module installation -->
|
|
<record model="mail.message" id="hr_timesheet_module_install_notification">
|
|
<field name="model">mail.channel</field>
|
|
<field name="res_id" ref="mail.channel_all_employees"/>
|
|
<field name="message_type">notification</field>
|
|
<field name="subtype_id" ref="mail.mt_comment"/>
|
|
<field name="subject">Timesheet Validation application installed!</field>
|
|
<field name="body"><![CDATA[<p>From the top menu "Human Resources", enter and validate timesheets and attendances.</p>]]></field>
|
|
</record>
|
|
|
|
<record id="ir_actions_server_timsheet_sheet" model="ir.actions.server">
|
|
<field name="sequence" eval="5"/>
|
|
<field name="state">code</field>
|
|
<field name="type">ir.actions.server</field>
|
|
<field name="model_id" ref="model_hr_timesheet_current_open"/>
|
|
<field name="code">action = pool.get('hr.timesheet.current.open').open_timesheet(cr, uid, None, context)</field>
|
|
<field name="condition">True</field>
|
|
<field name="name">My Timesheet</field>
|
|
</record>
|
|
|
|
<!-- Timesheet sheet related subtypes for messaging / Chatter -->
|
|
<record id="mt_timesheet_confirmed" model="mail.message.subtype">
|
|
<field name="name">Waiting Approval</field>
|
|
<field name="res_model">hr_timesheet_sheet.sheet</field>
|
|
<field name="default" eval="True"/>
|
|
<field name="description">waiting approval</field>
|
|
</record>
|
|
<record id="mt_timesheet_approved" model="mail.message.subtype">
|
|
<field name="name">Approved</field>
|
|
<field name="res_model">hr_timesheet_sheet.sheet</field>
|
|
<field name="default" eval="True"/>
|
|
<field name="description">Timesheet approved</field>
|
|
</record>
|
|
<!-- Department (Parent) related subtypes for messaging / Chatter -->
|
|
<record id="mt_department_timesheet_confirmed" model="mail.message.subtype">
|
|
<field name="name">Timesheets to Approve</field>
|
|
<field name="res_model">hr.department</field>
|
|
<field name="default" eval="False"/>
|
|
<field name="parent_id" eval="ref('mt_timesheet_confirmed')"/>
|
|
<field name="relation_field">department_id</field>
|
|
<field name="sequence" eval="5"/>
|
|
</record>
|
|
<record id="mt_department_timesheet_approved" model="mail.message.subtype">
|
|
<field name="name">Timesheets Approved</field>
|
|
<field name="res_model">hr.department</field>
|
|
<field name="default" eval="False"/>
|
|
<field name="parent_id" eval="ref('mt_timesheet_approved')"/>
|
|
<field name="relation_field">department_id</field>
|
|
<field name="sequence" eval="5"/>
|
|
</record>
|
|
|
|
</data>
|
|
</openerp>
|