Merge pull request #19112 from rohitwaghchaure/fixed_get_bin_details_and_serial_nos_arugument_passing_issue

fix: get_bin_details_and_serial_nos() takes at least 3 arguments (4 g…
This commit is contained in:
rohitwaghchaure 2019-09-19 18:01:03 +05:30 committed by GitHub
commit 6bbc834f8f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -234,7 +234,7 @@ erpnext.selling.SellingController = erpnext.TransactionController.extend({
args: {
item_code: item.item_code,
warehouse: item.warehouse,
has_batch_no: has_batch_no,
has_batch_no: has_batch_no || 0,
stock_qty: item.stock_qty,
serial_no: item.serial_no || "",
},

View File

@ -808,7 +808,7 @@ def get_serial_no_details(item_code, warehouse, stock_qty, serial_no):
return {'serial_no': serial_no}
@frappe.whitelist()
def get_bin_details_and_serial_nos(item_code, warehouse, has_batch_no, stock_qty=None, serial_no=None):
def get_bin_details_and_serial_nos(item_code, warehouse, has_batch_no=None, stock_qty=None, serial_no=None):
bin_details_and_serial_nos = {}
bin_details_and_serial_nos.update(get_bin_details(item_code, warehouse))
if flt(stock_qty) > 0: