delete calende
This commit is contained in:
parent
7fccd99d60
commit
22dd19657d
|
|
@ -10,45 +10,61 @@
|
|||
<field name="search_view_id" ref="hr_holidays_community.view_hr_holidays_filter"/>
|
||||
</record>
|
||||
|
||||
<!-- <record model="ir.actions.act_window" id="leaves_balance_actionn">-->
|
||||
<!-- <field name="name">Leaves Balance</field>-->
|
||||
<!-- <field name="res_model">hr.holidays</field>-->
|
||||
<!-- <field name="view_mode">tree,form</field>-->
|
||||
<!-- <field name="domain">[('type','=','add'),('check_allocation_view','=','balance')]</field>-->
|
||||
<!-- <field name="context">{'search_default_employee_id': [active_id], 'default_employee_id': active_id, 'search_default_group_type': 1,-->
|
||||
<!-- 'search_default_year': 1,'default_type':'add', 'default_check_allocation_view': 'balance'}</field>-->
|
||||
<!-- <field name="search_view_id" ref="hr_holidays_community.view_hr_holidays_filter"/>-->
|
||||
<!-- </record>-->
|
||||
<record id="view_hr_holidays_tree_no_delete" model="ir.ui.view">
|
||||
<field name="name">hr.holidays.tree.no.delete</field>
|
||||
<field name="model">hr.holidays</field>
|
||||
<field name="inherit_id" ref="hr_holidays_public.leaves_balance_tree_view"/>
|
||||
<field name="arch" type="xml">
|
||||
<tree position="attributes">
|
||||
<attribute name="delete">false</attribute>
|
||||
<attribute name="edit">false</attribute>
|
||||
<attribute name="create">false</attribute>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_hr_holidays_form_no_delete" model="ir.ui.view">
|
||||
<field name="name">hr.holidays.form.no.delete</field>
|
||||
<field name="model">hr.holidays</field>
|
||||
<field name="inherit_id" ref="hr_holidays_community.edit_holiday_new"/>
|
||||
<field name="arch" type="xml">
|
||||
<form position="attributes">
|
||||
<attribute name="delete">false</attribute>
|
||||
<attribute name="edit">false</attribute>
|
||||
<attribute name="create">false</attribute>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record model="ir.actions.act_window" id="leaves_balancee_action">
|
||||
<field name="name">Leaves Balance</field>
|
||||
<field name="res_model">hr.holidays</field>
|
||||
<field name="view_mode">tree,form</field>
|
||||
<field name="view_ids" eval="[
|
||||
(5, 0, 0),
|
||||
(0, 0, {'view_mode': 'tree', 'view_id': ref('view_hr_holidays_tree_no_delete')}),
|
||||
(0, 0, {'view_mode': 'form', 'view_id': ref('hr_holidays_public.leaves_balance_form_view')})
|
||||
]"/>
|
||||
<field name="domain">[('type','=','add'),('check_allocation_view','=','balance')]</field>
|
||||
<field name="context">{'search_default_employee_id': [active_id], 'default_employee_id': active_id, 'search_default_group_type': 1,
|
||||
'search_default_year': 1}</field>
|
||||
<field name="search_view_id" ref="hr_holidays_community.view_hr_holidays_filter"/>
|
||||
</record>
|
||||
|
||||
|
||||
|
||||
<record id="view_employee_form_leave_inheritt" model="ir.ui.view">
|
||||
<field name="name">hr.employee.leave.form.inherit</field>
|
||||
<field name="model">hr.employee</field>
|
||||
<field name="inherit_id" ref="hr.view_employee_form"/>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//group[@name='active_group']" position="after">
|
||||
<group string="Leaves" groups="base.group_no_one">
|
||||
<label for="remaining_leaves"/>
|
||||
<div>
|
||||
<field name="remaining_leaves" class="oe_inline"/> days
|
||||
</div>
|
||||
</group>
|
||||
</xpath>
|
||||
<xpath expr="//div[@name='button_box']" position="inside">
|
||||
<field name="show_leaves" invisible="1"/>
|
||||
<button name="%(leaves_balance_actionn)d"
|
||||
type="action"
|
||||
class="oe_stat_button"
|
||||
icon="fa-calendar"
|
||||
attrs="{'invisible': [('show_leaves','=', False)]}"
|
||||
groups="base.group_user"
|
||||
help="Remaining leaves">
|
||||
<field string="Leaves Left" name="leaves_count" widget="statinfo"/>
|
||||
</button>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_employee_form_leave_inherit_custom" model="ir.ui.view">
|
||||
<field name="name">hr.employee.leave.form.inherit.custom</field>
|
||||
<field name="model">hr.employee</field>
|
||||
<field name="inherit_id" ref="hr_holidays_community.view_employee_form_leave_inherit"/>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//button[@name='%(hr_holidays_community.act_hr_employee_holiday_request)d']" position="attributes">
|
||||
<attribute name="name">%(hr_holidays_public.leaves_balancee_action)d</attribute>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue