-
-
Notifications
You must be signed in to change notification settings - Fork 750
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
[14.0][FIX] project_milestone : Wrong assignment of tasks to milestones when duplicating a project #1283 #1284
base: 14.0
Are you sure you want to change the base?
Conversation
…es when duplicating a project OCA#1283
Hi @patrickrwilson, |
@OCA/project-maintainers : Here is a fix for issue #1283 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code review, LGTM.
I wonder if there's a more robust way of finding the milestone instead of using the name. Maybe instead of copy=True
the milestones could be copied "manually" inside the copy
function, in order to have a mapping between old and new milestones.
milestone = project.milestone_ids.filtered( | ||
lambda milestone: "2" not in milestone.name | ||
) | ||
assert tasks[0].milestone_id == milestone and tasks[1].milestone_id == milestone |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
chore (non-blocking): would prefer the usage of self.assertTrue
or similar instead of the raw assert
@OCA/project-service-maintainers : Thank you for your review |
Fix for issue #1283