fix: force reload of Opportunity in patch (#26668)

This commit is contained in:
Raffael Meyer 2021-07-27 20:44:59 +02:00 committed by GitHub
parent 965b1fe4a0
commit ac2e139d5b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -37,7 +37,7 @@ def execute():
if frappe.db.exists('DocType', 'Opportunity'):
opportunities = frappe.db.get_all('Opportunity', fields=['name', 'mins_to_first_response'], order_by='creation desc')
frappe.reload_doc('crm', 'doctype', 'opportunity')
frappe.reload_doctype('Opportunity', force=True)
rename_field('Opportunity', 'mins_to_first_response', 'first_response_time')
# change fieldtype to duration