Skip to content

Commit

Permalink
[MODORDERS-1085] - Add ability to search by location and holding in P…
Browse files Browse the repository at this point in the history
…OL (#903)

(cherry picked from commit 29700d9)
  • Loading branch information
Abdulkhakimov authored and azizbekxm committed Apr 19, 2024
1 parent 9ec9eca commit 3419405
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
5 changes: 3 additions & 2 deletions descriptors/ModuleDescriptor-template.json
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,6 @@
"orders.re-encumber.item.post"
],
"modulePermissions": [
"inventory-storage.holdings.collection.get",
"orders-storage.purchase-orders.item.get",
"orders-storage.po-lines.collection.get",
"orders-storage.po-lines-batch.collection.put",
Expand All @@ -133,7 +132,8 @@
"finance.ledger-rollovers-errors.collection.get",
"finance.ledger-rollovers-errors.item.delete",
"finance.exchange-rate.item.get",
"finance-storage.ledgers.collection.get"
"finance-storage.ledgers.collection.get",
"inventory-storage.holdings.collection.get"
]
}
]
Expand Down Expand Up @@ -583,6 +583,7 @@
"inventory.items.collection.get",
"inventory-storage.holdings.item.get",
"inventory-storage.holdings.item.delete",
"inventory-storage.holdings.collection.get",
"finance.funds.collection.get",
"finance.funds.budget.item.get",
"finance.fiscal-years.item.get",
Expand Down
2 changes: 2 additions & 0 deletions src/main/java/org/folio/helper/PurchaseOrderLineHelper.java
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,7 @@ public class PurchaseOrderLineHelper {

private static final Pattern PO_LINE_NUMBER_PATTERN = Pattern.compile("([a-zA-Z0-9]{1,22}-)(\\d{1,3})");
private static final String PURCHASE_ORDER_ID = "purchaseOrderId";
private static final String SEARCH_LOCATION_IDS = "searchLocationIds";
private static final String CREATE_INVENTORY = "createInventory";
public static final String ERESOURCE = "eresource";
public static final String PHYSICAL = "physical";
Expand Down Expand Up @@ -216,6 +217,7 @@ public Future<CompositePoLine> createPoLine(CompositePoLine compPoLine, Composit
.compose(v -> generateLineNumber(compOrder, requestContext))
.map(lineNumber -> line.put(PO_LINE_NUMBER, lineNumber))
.compose(v -> updateSearchLocations(compPoLine, requestContext))
.map(v -> line.put(SEARCH_LOCATION_IDS, compPoLine.getSearchLocationIds()))
.compose(v -> createPoLineSummary(compPoLine, line, requestContext));
}

Expand Down

0 comments on commit 3419405

Please sign in to comment.