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

OBPIH-6331 Inferring bin locations in pick import #4675

Merged
merged 18 commits into from
Jun 26, 2024
Merged
Changes from 1 commit
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
bed2d72
OBPIH-6331 Initial implementation of allocation rules on picklist dat…
jmiranda Jun 8, 2024
5fb71ec
OBPIH-6331 Added allocation request as well as validation; improved d…
jmiranda Jun 10, 2024
9e995d6
OBPIH-6331 Changes requested via code review; fixed bugs discovered d…
jmiranda Jun 11, 2024
6341f7c
OBPIH-6331 Fixed inadvertant typo that occurred during rebase onto de…
jmiranda Jun 16, 2024
5f656a3
OBPIH-6331 Added missing validation error when there are more than on…
jmiranda Jun 17, 2024
10f8709
OBPIH-6331 Added TODO comments for changes that should be made in the…
jmiranda Jun 17, 2024
f62d676
OBPIH-6331 Removed override "allocation" mechanism because we decided…
jmiranda Jun 17, 2024
f03f6e6
OBPIH-6331 Added another TODO comment for when we're ready to merge
jmiranda Jun 17, 2024
20bc1c3
OBPIH-6331 Commented out the revertPick from the rebase, kept clearPi…
jmiranda Jun 17, 2024
79c9aec
OBPIH-6420 Fix marking picklist as cleared (#4678)
alannadolny Jun 18, 2024
3de6342
OBPIH-6331 Fixed validation logic for scenario 4
jmiranda Jun 19, 2024
e43f166
OBPIH-6524 Fixed bug reported in Sentry (Ambiguous method overloading…
jmiranda Jun 20, 2024
03a285e
OBPIH-6526 Fixed bug reported in Sentry (No such property: g for clas…
jmiranda Jun 20, 2024
25c382a
OBPIH-6523 Changed logic for available quantity to validate whether t…
jmiranda Jun 20, 2024
32d93e3
OBPIH-6331 Minor improvements to comments and error message
jmiranda Jun 20, 2024
d479ab0
OBPIH-6331 Minor improvements to code readability and error messages
jmiranda Jun 20, 2024
17df3af
OBPIH-6522 Fixed bug related to allocating item from physical locatio…
jmiranda Jun 20, 2024
30901ea
OBPIH-6534 Fixed bug with allocation strategy when there was a single…
jmiranda Jun 20, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
OBPIH-6331 Fixed validation logic for scenario 4
  • Loading branch information
jmiranda committed Jun 19, 2024
commit 3de63422ead4ae117781c5b149459c4c6fbc216b
Original file line number Diff line number Diff line change
Expand Up @@ -1400,9 +1400,8 @@ class StockMovementService {
// }

// Scenario 3: All stock in receiving or default bin > if lot has stock entries only in hold bin > invalid
boolean isAllStockInHoldLocations = !availableItems.empty ? availableItems.every { it.onHold } : false
log.info "\n\nisAllStockInHoldLocations: " + isAllStockInHoldLocations
if (isAllStockInHoldLocations) {
boolean hasAllHoldLocations = !availableItems.empty ? availableItems.every { it.onHold } : false
if (hasAllHoldLocations) {
picklistItemCommand.errors.rejectValue("binLocation",
"allocationRequest.availableItems.inHoldLocations",
[product.productCode, inventoryItem?.lotNumber, availableItems.binLocationName] as Object [],
Expand All @@ -1411,12 +1410,13 @@ class StockMovementService {
}

// Scenario 4: Any other scenario (stock in “real” bin and virtual bin, stock in multiple real bins)
Integer countInVirtualAndBinLocations = availableItems?.findAll { it?.isVirtualLocation || it?.isBinLocation }?.size()
if (countInVirtualAndBinLocations > 1) {
boolean hasAnyBinLocations = availableItems?.any { it?.isBinLocation }
boolean hasAnyVirtualLocations = availableItems?.any { it?.isVirtualLocation }
if (hasAnyBinLocations && hasAnyVirtualLocations) {
picklistItemCommand.errors.rejectValue("binLocation",
"importPickCommand.availableItems.inMultipleLocations",
"importPickCommand.availableItems.inMultipleBinLocations",
[product.productCode, inventoryItem?.lotNumber, availableItems.binLocationName] as Object [],
"Product {0} with lot number {1} has stock in multiple bin locations {2}. Please indicate the bin location to pick from."
"Product {0} with lot number {1} has stock in multiple internal locations {2}. Please indicate the bin location to pick from."
)
}

Expand Down
Loading