diff --git a/erpnext/patches/v15_0/rename_sla_fields.py b/erpnext/patches/v15_0/rename_sla_fields.py index e5e69e0921e..6a7439ad257 100644 --- a/erpnext/patches/v15_0/rename_sla_fields.py +++ b/erpnext/patches/v15_0/rename_sla_fields.py @@ -9,10 +9,10 @@ def execute(): if doctype == "Issue": continue - if frappe.db.exists("Custom Field", {"fieldname": doctype + "-resolution_by"}): + if frappe.db.exists("Custom Field", {"name": doctype + "-resolution_by"}): rename_fieldname(doctype + "-resolution_by", "sla_resolution_by") - if frappe.db.exists("Custom Field", {"fieldname": doctype + "-resolution_date"}): + if frappe.db.exists("Custom Field", {"name": doctype + "-resolution_date"}): rename_fieldname(doctype + "-resolution_date", "sla_resolution_date") rename_field("Issue", "resolution_by", "sla_resolution_by")