[fix] [minor] update reserved qty

This commit is contained in:
Nabin Hait 2013-08-20 12:28:44 +05:30
parent 4ae729bfd2
commit c13c193bbc
3 changed files with 5 additions and 3 deletions

View File

@ -87,7 +87,9 @@ class StockController(AccountsController):
def delete_and_repost_sle(self):
""" Delete Stock Ledger Entries related to this voucher
and repost future Stock Ledger Entries"""
from stock.stock_ledger import update_entries_after
existing_entries = webnotes.conn.sql("""select distinct item_code, warehouse
from `tabStock Ledger Entry` where voucher_type=%s and voucher_no=%s""",
(self.doc.doctype, self.doc.name), as_dict=1)

View File

@ -290,7 +290,7 @@ class DocType(SellingController):
for d in self.get_item_list():
if webnotes.conn.get_value("Item", d.item_code, "is_stock_item") == "Yes" \
and d.warehouse:
self.update_reserved_qty()
self.update_reserved_qty(d)
if self.doc.docstatus == 1:
sl_entries.append(self.get_sl_entries(d, {

View File

@ -28,7 +28,7 @@ def make_entry(args):
sle = webnotes.bean([args])
sle.ignore_permissions = 1
sle.insert()
sle.submit()
# sle.submit()
return sle.doc.name
_exceptions = []