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

[16.0][FIX]mail_activity_done: Fix counters and activity_state search #1507

Open
wants to merge 4 commits into
base: 16.0
Choose a base branch
from

Conversation

jesusVMayor
Copy link
Member

@jesusVMayor jesusVMayor commented Nov 21, 2024

This PR includes 2 changes:

  • Remove systray_get_activities overrride, its not necessary since odoo/odoo@bd4e8aa
  • Override _search_activity_state adding and mail_activity.done=False to WHERE clause in the query to allow properly search by this field.

Fixes: #1327 CC: @gurneyalex @navarrorico

In odoo 16 the systray_get_activities function uses the ORM, there is no need to override it.
@jesusVMayor jesusVMayor force-pushed the 16.0_fix_activity_done branch 2 times, most recently from ea4838f to df64eed Compare November 21, 2024 13:51
@jesusVMayor
Copy link
Member Author

Fixed tests.

@jesusVMayor jesusVMayor force-pushed the 16.0_fix_activity_done branch from df64eed to 9ab7f24 Compare November 22, 2024 10:44
@jesusVMayor
Copy link
Member Author

I have detected a new bug, the _read_progress_bar inherit was not properly working and the count of activities in the kanban view was wrong. We should modify the subquery where clause

Copy link
Member

@hbrunn hbrunn left a comment

Choose a reason for hiding this comment

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

looks like you'll have to update the test too - I think it's correct to expect a 0 here

@jesusVMayor jesusVMayor force-pushed the 16.0_fix_activity_done branch from 1f68c55 to 1f6bc04 Compare December 30, 2024 15:50
@jesusVMayor
Copy link
Member Author

Seems a problem with the tests because the function executes the query directly. Testing in shell, if i make the commit after the _action_done, the result is 0. It also happens in the test_activity_state_search.

I changed the tests to move the second activity to demo file, assigned to another partner, and created already done.

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.

mail_activity_done: wrong counters
2 participants