Skip to content

Commit dbb6ad4

Browse files
committed
[IMP] hr_employee : make UX improvements
task - 3203838 closes odoo#114280 Related: odoo/enterprise#37749 Signed-off-by: Kevin Baptiste <kba@odoo.com>
1 parent e9ba4ae commit dbb6ad4

File tree

5 files changed

+6
-7
lines changed

5 files changed

+6
-7
lines changed

addons/hr/views/hr_employee_views.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@
112112
options='{"always_reload": True, "highlight_first_line": True}'/>
113113
<field name="work_location_id" context="{'default_address_id': address_id}" />
114114
</group>
115-
<group name="managers" string="Approvers" class="hide-group-if-empty">
115+
<group name="managers" string="Approvers" class="hide-group-if-empty" invisible="1">
116116
<!-- is overridden in other hr related modules -->
117117
</group>
118118
<group name="departure" string="Departure" attrs="{'invisible': [('active', '=', True)]}">
@@ -196,7 +196,7 @@
196196
<group string='Payroll' name="payroll_group">
197197
<field name="job_id"/>
198198
</group>
199-
<group name="application_group"/>
199+
<group name="application_group" string="Application Settings" invisible="1"/>
200200
</group>
201201
</page>
202202
</notebook>

addons/hr_fleet/views/employee_views.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
</button>
1616
</div>
1717
<group name="application_group" position="attributes">
18-
<attribute name="string">Application Settings</attribute>
18+
<attribute name="invisible">0</attribute>
1919
</group>
2020
<group name="application_group" position="inside">
2121
<field name="mobility_card" string="Fleet Mobility Card"/>

addons/hr_holidays/models/hr_employee.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,8 +86,7 @@ def _compute_allocation_count(self):
8686
('holiday_status_id.active', '=', True),
8787
('holiday_status_id.requires_allocation', '=', 'yes'),
8888
('state', '=', 'validate'),
89-
'|',
90-
('date_to', '=', False),
89+
('date_from', '<=', current_date),
9190
('date_to', '>=', current_date),
9291
], ['number_of_days:sum', 'employee_id'], ['employee_id'])
9392
rg_results = dict((d['employee_id'][0], {"employee_id_count": d['employee_id_count'], "number_of_days": d['number_of_days']}) for d in data)

addons/hr_hourly_cost/views/hr_employee_views.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<field name="priority" eval="40"/>
88
<field name="arch" type="xml">
99
<group name="application_group" position="attributes">
10-
<attribute name="string">Application Settings</attribute>
10+
<attribute name="invisible">0</attribute>
1111
</group>
1212
<group name="application_group" position="inside">
1313
<label for="hourly_cost"/>

addons/hr_org_chart/static/src/fields/hr_org_chart.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
t-att-style="'background-image:url(\'/web/image/hr.employee.public/' + employee.id + '/avatar_1024/\')'"/>
3636
</div>
3737

38-
<div class="d-flex flex-grow-1 align-items-start justify-content-between position-relative px-3">
38+
<div class="d-flex flex-grow-1 align-items-center justify-content-between position-relative px-3">
3939
<a t-if="!is_self" t-att-href="employee.link" class="o_employee_redirect d-flex flex-column" t-att-data-employee-id="employee.id" t-on-click.prevent="() => this._onEmployeeRedirect(employee.id)">
4040
<b class="o_media_heading m-0 fs-6" t-esc="employee.name"/>
4141
<small class="text-muted fw-bold" t-esc="employee.job_title"/>

0 commit comments

Comments
 (0)