Skip to content

Commit

Permalink
Merge pull request #43 from hotwax/#42_get_cycle_count_items_api
Browse files Browse the repository at this point in the history
Improved: Included parentProductId and parentProductName in Get Cycle Count Items API (#42).
  • Loading branch information
dixitdeepak authored Jan 14, 2025
2 parents 732b341 + 5e51216 commit 079f041
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions service/co/hotwax/cycleCount/InventoryCountServices.xml
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,16 @@
<econdition field-name="statusId" value="INV_COUNT_COMPLETED" />
</entity-find>
<set field="itemDetail.acceptedByUserLoginId" from="itemStatusHistory?.first?.changeByUserLoginId"/>

<!-- fetch the Parent Product details -->
<entity-find entity-name="org.apache.ofbiz.product.product.ProductAssocAndFrom" list="parentProductDetails">
<econdition field-name="productIdTo" from="inventoryItem.productId"/>
<econdition field-name="productAssocTypeId" value="PRODUCT_VARIANT"/>
<date-filter/>
</entity-find>
<set field="itemDetail.parentProductId" from="parentProductDetails?.first?.productId"/>
<set field="itemDetail.parentProductName" from="parentProductDetails?.first?.productName"/>

<script>itemList.add(itemDetail)</script>
</iterate>
</actions>
Expand Down

0 comments on commit 079f041

Please sign in to comment.