Move reload doc before get query
This commit is contained in:
parent
3a2f342ac1
commit
053d6a2ca1
@ -7,11 +7,13 @@ import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
items_barcode = frappe.get_all('Item', ['name', 'barcode'], { 'barcode': ('!=', '') })
|
||||
|
||||
frappe.reload_doc("stock", "doctype", "item")
|
||||
frappe.reload_doc("stock", "doctype", "item_barcode")
|
||||
|
||||
items_barcode = frappe.get_all('Item', ['name', 'barcode'], { 'barcode': ('!=', '') })
|
||||
frappe.reload_doc("stock", "doctype", "item")
|
||||
|
||||
|
||||
|
||||
for item in items_barcode:
|
||||
barcode = item.barcode.strip()
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user