Merge pull request #4153 from rmehta/stock-entry-fix

[fix] [minor] stock_entry.py error for None qty
This commit is contained in:
Rushabh Mehta 2015-10-12 18:32:28 +05:30
commit d256055a8c

View File

@ -102,7 +102,7 @@ class StockEntry(StockController):
if self.difference_account and not item.expense_account: if self.difference_account and not item.expense_account:
item.expense_account = self.difference_account item.expense_account = self.difference_account
if not item.transfer_qty: if not item.transfer_qty and item.qty:
item.transfer_qty = item.qty * item.conversion_factor item.transfer_qty = item.qty * item.conversion_factor
if (self.purpose in ("Material Transfer", "Material Transfer for Manufacture") if (self.purpose in ("Material Transfer", "Material Transfer for Manufacture")