* = hr, hr_holidays, hr_homeworking
Changes the hover on plane icon for leave. In public employee the hover is : "on leave" and in private employee the hover is the name of type's leave
task : 3527398
closesodoo/odoo#137741
Signed-off-by: Sofie Gvaladze (sgv) <sgv@odoo.com>
Co-authored-by: Xavier Bol <xbo@odoo.com>
* = hr, hr_holidays, hr_homeworking
Change the disposition in Kanban card.
Changes the behavior of the image in the kanban card: if an employee don't have an image the avatar's image is displayed.
task : 3527398
closesodoo/odoo#138858
X-original-commit: c55dd60baa8aeb6d54a2dc7f1039be1e84113cf8
Related: odoo/upgrade#5314
Signed-off-by: Sofie Gvaladze (sgv) <sgv@odoo.com>
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
The attendance dropdown is a switch button and "Needs Action" is no
longer visible on the popover (instead none of the buttons are selected)
The popovers are larger and the icons aligned. Their headers are the
color of their event.
The year view's event links inside the popovers have the same styling
as their event in the calendar.
task-3389317
Part-of: odoo/odoo#138670
In some modules at Odoo we want to have custom headers for calendar. Since
fullcalendar accepts a function callback that should render the header, it was
decided to have this method exist in the calendar_common_renderer. So any
other apps that want to add something to the header, can just extend this
method. This commit also changes how homeworking changes the header so that it
complies with this change.
task-3455051
task-3389317
Part-of: odoo/odoo#138670
Before this commit, when the locale was not in english, the following
traceback was observed:
```
Uncaught (in promise) Error: The following error occurred in onWillStart: "res[employeeId][((intermediate value) + "_location_id")] is undefined"
OwlError owl.js:87
wrapError owl.js:2604
onWillStart owl.js:2647
useModelWithSampleData model.js:165
setup calendar_controller.js:48
setup attendee_calendar_controller.js:10
setup appointment_calendar_controller.js:15
setup google_calendar_controller.js:11
setup hr_homeworking_calendar_controller.js:12
setup microsoft_calendar_controller.js:11
```
closesodoo/odoo#139052
Signed-off-by: Arnaud Joset (arj) <arj@odoo.com>
https://github.com/odoo/odoo/pull/137502 changed how we handle homeworking
records. However, it would throw a traceback if luxon was using any non
english localizations to get the week name of a date. This commit fixes this by
setting the us location before getting the weekname as we rely on it to get the
default data for that day.
closesodoo/odoo#138831
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
Before this commit, the hr presence status icon is hardcoded in
each view in which the icon is needed.
This commit creates a widget for that icon to be able to use that
widget in the views in which the icon is needed to avoid duplicating
the code.
task-3376776
This commit prevents deleting worklocations if they are used as default of an
employee. In case the worklocation is deleted, exceptions using that
worklocation are also deleted.
task-3527196
closesodoo/odoo#137502
Related: odoo/upgrade#5260
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
This commit changes how hr_homeworking deals with hr.employee.homework records.
Before this, an hr.employee.homework record was created for each day of the
week, even if it was the default location of the employee. This commit reworks
how homeworking deals with them to reduce the amount of records generated.
Now default employee locations don't generate records. They are rendered in the
calendar view as ghost events. For exceptions, we allow only creating a single
exception per day. If an employee sets an exception as 'weekly', it sets that
location as the default one for the employee on that day of the week. Not
having to deal with recurrencies makes the homeworking code simpler to manage
as well. Also exceptions are, by definition, not common. So we shouldn't expect
a lot of exception records to be created.
task-3527196
Part-of: odoo/odoo#137502
current behavior:
If you have a weekly location defined on the employee,
and a exeptional, location for that day defined on the Calendar,
the presnece icon shows weekly and not the exceptional.
Expected behavior:
Presence icon should be based on the exceptional location,
and if there are none, take the weekly one.
task-3482527
closesodoo/odoo#135191
X-original-commit: cbb4d588e3a1dd1f89f19ac3a413bd531f8a5729
Signed-off-by: Yannick Tivisse (yti) <yti@odoo.com>
luxon and moment are both used in the solution, but these two libraries
facilitate the manipulation of dates. It was decided to replace all uses of
moment with luxon so we can then remove moment.js from the code and lighten
the assets.
task-3391739
closesodoo/odoo#133144
Related: odoo/enterprise#46447
Signed-off-by: Bruno Boi (boi) <boi@odoo.com>
This commit fixes 3 bugs
------
Prior:
Deleting a weekly record from the calendar didn't remove it from the
employee's profile
Steps:
• Have a weekly location for the employee for Wednesday
• Go to the calendar and remove Wednesday location and choose that it's
removed for everyweek
• Check employee card
Current behavior: The weekly location for Wednesday still appears on the
employee profile.
Expected: The weekly location for Wednesday is empty
------
Prior:
Deleting a weekly record from the employee's profile removed all records
from the calendar.
Expected behavior: When a weekly location is removed from the employee's
profile only future records should be removed, the past records should
stay untouched.
------
Prior:
When hr_homeworking is installed, if there is a work location set for
the day it is shown on the employee's kanban card, but when it's not
specified it shows nothing, which can be confusing.
Expected: Show 'Unspecified' when location is not set.
task - 3439421
closesodoo/odoo#133671
X-original-commit: 9212e2ff95be61528cc9d249e6f2baec770b8907
Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
In this commit, all usages of env._t() are replaced by _t().
In templates files, env._t() didn't work because terms used
in attributes where not extracted into the translation files.
Only string are exported from .xml files to translation files.
So, to make it works, we set a variable that is then used
in attributes.
For example :
<t t-set="string_to_translate">String to translate</t>
<Dialog title="string_to_translate>...</Dialog>
task-3292454
closesodoo/odoo#131390
Related: odoo/enterprise#45631
Signed-off-by: Michaël Mattiello (mcm) <mcm@odoo.com>
As all the templates are now imported in the owl app, there is not need
anymore to specify the owl="1" attribute in the templates.
Part of task~3443861
Part-of: odoo/odoo#130467
In the commit [1], the patch has been refactored to support the
native keyword `super`. The current commit just adapts the codebase
to that change.
task 3410198
[1]: 19ea1ac08043e22a811630968e44715cc3bfc495
Part-of: odoo/odoo#125716
Users and employees can now define their usual worklocation
for a day of the week aswell as define unusual ones from the
calendar app. The worklocation is then displayed in the calendar
in two different ways: when only one person is selected, there
is a circle with an icon in it, and a ray that extends to the right
if the person is at the same location for multiple days. If there
are multiple persons selected there is no ray, instead the circles
are grouped by location type and colored accordingly to the filters
in the left panel.
closesodoo/odoo#129585
Task: 3060685
X-original-commit: c74ac3f698d4ea4c9b7a5e060fba4cf77cc9a6d7
Signed-off-by: Kevin Baptiste <kba@odoo.com>
Co-authored-by: dasz <dasz@odoo.com>