Skip to content

[18.0][IMP] dms_field: Use ir.assets for xml to add the sequence and avoid race condition with hr_holidays accrual plan#448

Merged
OCA-git-bot merged 1 commit intoOCA:18.0from
dixmit:18.0-accrual
Oct 3, 2025
Merged

Conversation

@etobella
Copy link
Copy Markdown
Member

@etobella etobella commented Oct 3, 2025

We have detected that the dms_field way of defining the field is providing issues with hr_holidays on the view accural. If hr_holidays and dms_field are both installed and we try to access accruals, we receive the following error:

image

this comes from the definition of accrual plan widget in 18 (fixed in 19). The way I found to solve it is to move the DMSList in this case too.

https://github.com/odoo/odoo/blob/18.0/addons/hr_holidays/static/src/xml/x2many_field.xml

It affects 17.0 too, but not 16.0

@pedrobaeza pedrobaeza added this to the 18.0 milestone Oct 3, 2025
@pedrobaeza
Copy link
Copy Markdown
Member

Can't you trick the position of loading here?

"/web/static/src/views/fields/x2many/x2many_field.xml",

…race condition with hr_holidays accrual plan
@etobella
Copy link
Copy Markdown
Member Author

etobella commented Oct 3, 2025

Not directly, but by using ir.assets I am able to do that. WDYT?

@pedrobaeza
Copy link
Copy Markdown
Member

@CarlosRoca13 I think you did the asset thing. Can you check if this is correct?

Copy link
Copy Markdown
Contributor

@CarlosRoca13 CarlosRoca13 left a comment

Choose a reason for hiding this comment

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

Thanks!

Copy link
Copy Markdown
Member

@pedrobaeza pedrobaeza left a comment

Choose a reason for hiding this comment

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

/ocabot merge patch

@OCA-git-bot
Copy link
Copy Markdown
Contributor

What a great day to merge this nice PR. Let's do it!
Prepared branch 18.0-ocabot-merge-pr-448-by-pedrobaeza-bump-patch, awaiting test results.

@pedrobaeza pedrobaeza changed the title [ADD] dms_field_accrual [18.0][IMP] dms_field: Use ir.assets for xml to add the sequence and avoid race condition with hr_holidays accrual plan Oct 3, 2025
@OCA-git-bot OCA-git-bot merged commit bc8c7d4 into OCA:18.0 Oct 3, 2025
7 checks passed
@OCA-git-bot
Copy link
Copy Markdown
Contributor

Congratulations, your PR was merged at fe4a576. Thanks a lot for contributing to OCA. ❤️

@etobella etobella deleted the 18.0-accrual branch October 3, 2025 07:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants