* [fix] remove razorpay from integration service * [fix] clean-up js side integration service dependancies * [fix] remove integration service, .py cleanup, move integration request to integration * [fix] move oauth to integrations and deprecate integration broker * [fix] mark services enabled and update integrations listing * [fix] V7.1 and V7.2 integration service related pathch fixes and move payment gateway dotype to core module * [fix] create payment gateway records if not exists * [fix] module page for integrations * [minor][fix] minor checks * [fix] remove integration broker module only if not allocated to any doctype
21 lines
494 B
Python
21 lines
494 B
Python
import frappe
|
|
from frappe.utils import cint
|
|
|
|
def execute():
|
|
frappe.reload_doc("integrations", "doctype", "ldap_settings")
|
|
|
|
if not frappe.db.exists("DocType", "Integration Service"):
|
|
return
|
|
|
|
if not frappe.db.exists("Integration Service", "LDAP"):
|
|
return
|
|
|
|
if not cint(frappe.db.get_value("Integration Service", "LDAP", 'enabled')):
|
|
return
|
|
|
|
import ldap
|
|
try:
|
|
ldap_settings = frappe.get_doc("LDAP Settings")
|
|
ldap_settings.save(ignore_permissions=True)
|
|
except ldap.LDAPError:
|
|
pass
|