Repository navigation
Conversation
a8dde6c to
2342555
Compare
2342555 to
36f1dbc
Compare
28ce3ab to
e970876
Compare
SirPyTech
left a comment
There was a problem hiding this comment.
Thanks for the changes 🙏
I think a few more edits are needed, and then we'll be good to go 🚀
e970876 to
efe4ea6
Compare
SirPyTech
left a comment
There was a problem hiding this comment.
The latest changes still need a little tweak in the depends, otherwise this looks good 👏🏻️
efe4ea6 to
93d5e8f
Compare
SirPyTech
left a comment
There was a problem hiding this comment.
Only code review, this looks good now, thanks!
Please resolve all the threads because I can't
| lot = move_line.lot_id | ||
| if lot not in qty_by_lot: | ||
| qty_by_lot[lot] = 0 | ||
| moved_qty = move_line.quantity |
There was a problem hiding this comment.
issue: Please convert the quantity as mentioned in #1643 (comment).
There was a problem hiding this comment.
Yes, it was missed to use quantity conversion in lot_ids computation
Display serial number under "Personal Equipment" Tab in Personal Equipment request form view when Personal Equipment Request is in "Accepted" state.
Using proper values for qty_delivered based on stock availability when a picking associated with allocation is validated/returned/scrapped. quantity conversion is also taken care while computing qty_delivered.
Refactored computation method of qty_delivered and lot_ids to use common methods for same logic.
df2d288 to
59f492f
Compare
59f492f to
df2d288
Compare
SirPyTech
left a comment
There was a problem hiding this comment.
Please fix the REF commit's title and description, if you want you can also add the test but it isn't required for approval on my side.
Also remember to resolve the older threads to cleanup the PR's comments because I can't.
| lot = move_line.lot_id | ||
| if lot not in qty_by_lot: | ||
| qty_by_lot[lot] = 0 | ||
| moved_qty = move_line.quantity |
| # Move lots needs to be verified | ||
| # for use case such as two | ||
| # allocations of same product used | ||
| # in same PPE request. If not, qty_delivered | ||
| # results in negative value when any one | ||
| # of the move is scrapped | ||
| and ( | ||
| [lot for lot in move.lot_ids if lot in self.move_ids.lot_ids] | ||
| if self.move_ids.lot_ids | ||
| else True | ||
| ) |
There was a problem hiding this comment.
bonus: For a bonus point 🏆️ I know we already talked about this check and you explained it well in the added comment, but I just tried executing the tests without this piece of code and they are still passing.
Can you consider adding a test for this use case that fails without this piece of code?
| for record in self: | ||
| record.skip_procurement = record._skip_procurement() | ||
|
|
||
| def _filter_allocation_moves(self): |
There was a problem hiding this comment.
chore: The commit that extracts this method should be a [IMP] because we are changing the logic: we are no more using move_ids, please also adjust the commit's title and description.
FW from 16.0 - #1497
Display serial number under "Personal Equipment" Tab in Personal Equipment request form view when Personal Equipment Request is in "Accepted" state.
Introduced improvements based on comments in a seperate commit such as usage of common method for filtering moves and using quantity conversion while computing qty_delivered. Same has been backported in 16.0 as part of PR #1668