Skip to content

Commit 9026b67

Browse files
Merge pull request #46418 from rohitwaghchaure/fixed-support-33273
fix: stock balance in and out value
2 parents 98690c4 + e917bd5 commit 9026b67

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

erpnext/stock/report/stock_balance/stock_balance.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -299,9 +299,12 @@ def prepare_item_warehouse_map(self, entry, group_by_key):
299299
elif entry.posting_date >= self.from_date and entry.posting_date <= self.to_date:
300300
if flt(qty_diff, self.float_precision) >= 0:
301301
qty_dict.in_qty += qty_diff
302-
qty_dict.in_val += value_diff
303302
else:
304303
qty_dict.out_qty += abs(qty_diff)
304+
305+
if flt(value_diff, self.float_precision) >= 0:
306+
qty_dict.in_val += value_diff
307+
else:
305308
qty_dict.out_val += abs(value_diff)
306309

307310
qty_dict.val_rate = entry.valuation_rate

0 commit comments

Comments
 (0)