7acdcc70ad
* fix: v12 doesn't have mandatory_depends_on field * fix: move update_vehicle_no_reqd_condition to v13 * fix: move update_vehicle_no_reqd_condition to v13 * fix: file name missing .py * refactor!: add back empty line * fix: linters issue
12 lines
349 B
Python
12 lines
349 B
Python
import frappe
|
|
|
|
|
|
def execute():
|
|
frappe.reload_doc('custom', 'doctype', 'custom_field')
|
|
company = frappe.get_all('Company', filters = {'country': 'India'})
|
|
if not company:
|
|
return
|
|
|
|
if frappe.db.exists('Custom Field', { 'fieldname': 'vehicle_no' }):
|
|
frappe.db.set_value('Custom Field', { 'fieldname': 'vehicle_no' }, 'mandatory_depends_on', '')
|