Merge pull request #3430 from expsa/hr_change_title

delete calende
This commit is contained in:
eslamtalaat744 2025-06-04 15:21:03 +03:00 committed by GitHub
commit 6adff93171
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 52 additions and 36 deletions

View File

@ -10,45 +10,61 @@
<field name="search_view_id" ref="hr_holidays_community.view_hr_holidays_filter"/> <field name="search_view_id" ref="hr_holidays_community.view_hr_holidays_filter"/>
</record> </record>
<!-- <record model="ir.actions.act_window" id="leaves_balance_actionn">--> <record id="view_hr_holidays_tree_no_delete" model="ir.ui.view">
<!-- <field name="name">Leaves Balance</field>--> <field name="name">hr.holidays.tree.no.delete</field>
<!-- <field name="res_model">hr.holidays</field>--> <field name="model">hr.holidays</field>
<!-- <field name="view_mode">tree,form</field>--> <field name="inherit_id" ref="hr_holidays_public.leaves_balance_tree_view"/>
<!-- <field name="domain">[('type','=','add'),('check_allocation_view','=','balance')]</field>--> <field name="arch" type="xml">
<!-- <field name="context">{'search_default_employee_id': [active_id], 'default_employee_id': active_id, 'search_default_group_type': 1,--> <tree position="attributes">
<!-- 'search_default_year': 1,'default_type':'add', 'default_check_allocation_view': 'balance'}</field>--> <attribute name="delete">false</attribute>
<!-- <field name="search_view_id" ref="hr_holidays_community.view_hr_holidays_filter"/>--> <attribute name="edit">false</attribute>
<!-- </record>--> <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> <record id="view_employee_form_leave_inherit_custom" model="ir.ui.view">
<field name="model">hr.employee</field> <field name="name">hr.employee.leave.form.inherit.custom</field>
<field name="inherit_id" ref="hr.view_employee_form"/> <field name="model">hr.employee</field>
<field name="arch" type="xml"> <field name="inherit_id" ref="hr_holidays_community.view_employee_form_leave_inherit"/>
<xpath expr="//group[@name='active_group']" position="after"> <field name="arch" type="xml">
<group string="Leaves" groups="base.group_no_one"> <xpath expr="//button[@name='%(hr_holidays_community.act_hr_employee_holiday_request)d']" position="attributes">
<label for="remaining_leaves"/> <attribute name="name">%(hr_holidays_public.leaves_balancee_action)d</attribute>
<div> </xpath>
<field name="remaining_leaves" class="oe_inline"/> days </field>
</div> </record>
</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>