Skip to content

Commit

Permalink
Merge pull request #32821 from frappe/mergify/bp/version-13-hotfix/pr…
Browse files Browse the repository at this point in the history
…-32788

fix: use `flt` instead of `cint` in `get_batch_no` (backport #32788)
  • Loading branch information
s-aga-r authored Nov 2, 2022
2 parents a914838 + 601b1e3 commit 5a21181
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion erpnext/stock/doctype/batch/batch.py
Original file line number Diff line number Diff line change
Expand Up @@ -285,7 +285,7 @@ def get_batch_no(item_code, warehouse, qty=1, throw=False, serial_no=None):
batches = get_batches(item_code, warehouse, qty, throw, serial_no)

for batch in batches:
if cint(qty) <= cint(batch.qty):
if flt(qty) <= flt(batch.qty):
batch_no = batch.batch_id
break

Expand Down

0 comments on commit 5a21181

Please sign in to comment.