Skip to content

Commit

Permalink
fix: add limit for get_next_stock_reco (#34937)
Browse files Browse the repository at this point in the history
fix: limit stock reco issue

(cherry picked from commit fcfa884)

Co-authored-by: Rohit Waghchaure <rohitw1991@gmail.com>
  • Loading branch information
mergify[bot] and rohitwaghchaure authored Apr 20, 2023
1 parent fef381e commit 7131ff2
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions erpnext/stock/stock_ledger.py
Original file line number Diff line number Diff line change
Expand Up @@ -1453,6 +1453,7 @@ def get_next_stock_reco(kwargs):
)
.orderby(CombineDatetime(sle.posting_date, sle.posting_time))
.orderby(sle.creation)
.limit(1)
)

if kwargs.get("batch_no"):
Expand Down

0 comments on commit 7131ff2

Please sign in to comment.