-
-
Notifications
You must be signed in to change notification settings - Fork 197
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
[IMP][14.0] shopfloor delivery: Better messages #972
[IMP][14.0] shopfloor delivery: Better messages #972
Conversation
a3738f3
to
a54680a
Compare
fb9cced
to
7bdedd1
Compare
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.
Can you also drop the commits from the other PR from this one and add a test-requirement.txt
to depend on the PR
message = self._check_picking_status(pickings, states=states) | ||
if message: | ||
return message | ||
message = self._check_picking_type(pickings) | ||
if message: | ||
return message |
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.
You should first check the picking type and then call _check_picking_status on the pickings with the right picking type.
Maybe _check_picking_type can return the list of filtered pickings and raise error if that list is empty.
Then call _check_picking_status on that result.
This is to ensure that you check the status on the pickings to process and not on a picking with a wrong picking type.
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.
And extract if not pickings.exists()
from _check_picking_status
as it's not a status. This should be the first test. Then test picking type. And then test picking status.
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.
And extract if not pickings.exists()
from _check_picking_status
as it's not a status. This should be the first test. Then test picking type. And then test picking status.
closed in favor of closed in favor of #987 |
Now that return moves are possibly being created when a picking is unreleased, display a nice message to the user when trying to process a product that should be returned in stock.
Based on #971