Skip to content

Commit cabea2f

Browse files
fix(stock): set incoming rate as zero for outward sle (backport #54514) (#54533)
fix(stock): set incoming rate as zero for outward sle (cherry picked from commit ce37530) Co-authored-by: Sudharsanan11 <sudharsananashok1975@gmail.com>
1 parent 4c95daa commit cabea2f

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

erpnext/stock/stock_ledger.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -955,6 +955,9 @@ def process_sle(self, sle):
955955
if not self.wh_data.qty_after_transaction:
956956
self.wh_data.stock_value = 0.0
957957

958+
if sle.actual_qty < 0:
959+
sle.incoming_rate = 0
960+
958961
stock_value_difference = self.wh_data.stock_value - self.wh_data.prev_stock_value
959962
self.wh_data.prev_stock_value = self.wh_data.stock_value
960963

0 commit comments

Comments
 (0)