mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-05 13:24:47 +00:00
[patches] [fix] replace sync with reload_doc in old patches
This commit is contained in:
@@ -12,8 +12,7 @@ def execute():
|
||||
clean_docfield_properties()
|
||||
|
||||
def change_property_setter_fieldnames():
|
||||
import webnotes.model.sync
|
||||
webnotes.model.sync.sync('core', 'property_setter')
|
||||
webnotes.reload_doc('core', 'doctype', 'property_setter')
|
||||
docfield_list = webnotes.conn.sql("""\
|
||||
SELECT name, fieldname FROM `tabDocField`""", as_list=1)
|
||||
custom_field_list = webnotes.conn.sql("""\
|
||||
|
||||
@@ -94,8 +94,7 @@ from webnotes.model.code import get_obj
|
||||
from webnotes.model.doc import Document
|
||||
|
||||
def execute():
|
||||
import webnotes.model.sync
|
||||
webnotes.model.sync.sync('core', 'custom_field')
|
||||
webnotes.reload_doc('core', 'doctype', 'custom_field')
|
||||
for f in field_list:
|
||||
res = webnotes.conn.sql("""SELECT name FROM `tabCustom Field`
|
||||
WHERE dt=%s AND fieldname=%s""", (f[0], f[1]))
|
||||
|
||||
Reference in New Issue
Block a user