Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FIX] project_timesheet_holidays: fix read error on employee_ids #174682

Closed
wants to merge 1 commit into from

Conversation

rch-asl
Copy link
Contributor

@rch-asl rch-asl commented Jul 26, 2024

Description of the issue/feature this PR addresses:

This commit fixes a read access error on the field employee_ids of hr_leave when a user, who is not in group_hr_holidays_user, tries to cancel/refuse a timeoff. The bug only appears when the timeoff crosses a public holiday.

Current behavior before PR:

An access error pops up when an user , who is not a timeoff officer/admin, tries to cancel a timeoff. The timeoff should cross a public holiday in order for the bug to appear.

Desired behavior after PR is merged:

The user is able to cancel its timeoff even if he/she is not a timeoff officer/admin.


I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr

@robodoo
Copy link
Contributor

robodoo commented Jul 26, 2024

Pull request status dashboard

@C3POdoo C3POdoo requested a review from a team July 26, 2024 13:34
@rch-asl
Copy link
Contributor Author

rch-asl commented Jul 26, 2024

@xavierbol @goffauxs Je vous tag car ça concerne du code que vous avez écrit/approuvé :)

@xavierbol
Copy link
Contributor

xavierbol commented Jul 29, 2024

Hello @rch-asl 👋🏼

Thanks for your contribution! 🤩
The fix looks good to me! 🟢

May I ask you to also add a unit test? 😇

Thanks in advance!

Have a nice day! 🙂


Bonjour @rch-asl 👋🏼

Merci pour ta contribution ! 🤩

Le fix me parait bon ! 🟢

Est-ce que je peux te demander d'ajouter également un test unitaire? 😇

Merci d'avance !

Passe une bonne journée ! 🙂 🌞

@xavierbol
Copy link
Contributor

@rch-asl
Oups pardon, tellement l'habitude que les conversations soient en anglais que j'ai direct répondu en anglais. 🙈

Mais bon j'imagine que tu as compris. 🙂

J'ai édité le message, on peut en effet continuer la discussion en français ou anglais. 🙂

@rch-asl rch-asl force-pushed the fix-timeoff-refusal-rch branch 2 times, most recently from 5f5f51d to 7a7bde3 Compare July 30, 2024 09:15
@rch-asl
Copy link
Contributor Author

rch-asl commented Jul 30, 2024

@xavierbol Haha I'm sorry for using French, it's indeed better to use English so everyone can understand :)
Thanks for your quick answer, I've added the unit test as requested!
Have a nice day!

This commit fixes a read access error on the field employee_ids of
hr_leave when a user, who is not in group_hr_holidays_user, tries to
cancel/refuse a timeoff. The bug only appears when the timeoff crosses a
public holidays.
Copy link
Contributor

@xavierbol xavierbol left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks again for your work! 😁 🚀

robodoo r+

robodoo pushed a commit that referenced this pull request Aug 2, 2024
This commit fixes a read access error on the field employee_ids of
hr_leave when a user, who is not in group_hr_holidays_user, tries to
cancel/refuse a timeoff. The bug only appears when the timeoff crosses a
public holidays.

closes #174682

Signed-off-by: Xavier Bol (xbo) <xbo@odoo.com>
@robodoo robodoo closed this Aug 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants