sales_order.py -- Three changes are done (a) if bypass credit limit check is enabled we should not check customer credit on submit of sales order (b.1/b.2) There is provision to make delivery note and sales invoice from sales order. Since credit limit is bypassed at sales order level we need to check credit of customer on make of (b.1)delivery note or (b.2)sales invoice. cint function is added.
diff --git a/erpnext/selling/doctype/sales_order/sales_order.py b/erpnext/selling/doctype/sales_order/sales_order.py
index d68f095..69e91e1 100644
--- a/erpnext/selling/doctype/sales_order/sales_order.py
+++ b/erpnext/selling/doctype/sales_order/sales_order.py
@@ -198,7 +198,7 @@
 		from erpnext.selling.doctype.customer.customer import check_credit_limit
 	    #PR : 10861, Author : ashish-greycube & jigneshpshah,  Email:mr.ashish.shah@gmail.com 
 		# bypass credit limit check is set to true (1) at sales order level, then we need not to check credit limit and vise versa
-		bypass_credit_limit_check_at_sales_order = frappe.db.get_value("Customer", self.customer, "bypass_credit_limit_check_at_sales_order")
+		bypass_credit_limit_check_at_sales_order = cint(frappe.db.get_value("Customer", self.customer, "bypass_credit_limit_check_at_sales_order"))
 		if bypass_credit_limit_check_at_sales_order == 0:
 			check_credit_limit(self.customer, self.company)
 
@@ -351,15 +351,15 @@
 		return items
 
 	def on_recurring(self, reference_doc, subscription_doc):
-		self.set("delivery_date", get_next_schedule_date(reference_doc.delivery_date, subscription_doc.frequency,
-			cint(subscription_doc.repeat_on_day)))
+		self.set("delivery_date", get_next_schedule_date(reference_doc.delivery_date,
+			subscription_doc.frequency, cint(subscription_doc.repeat_on_day)))
 
 		for d in self.get("items"):
 			reference_delivery_date = frappe.db.get_value("Sales Order Item",
 				{"parent": reference_doc.name, "item_code": d.item_code, "idx": d.idx}, "delivery_date")
 
-			d.set("delivery_date",
-				get_next_schedule_date(reference_delivery_date, subscription_doc.frequency, cint(subscription_doc.repeat_on_day)))
+			d.set("delivery_date", get_next_schedule_date(reference_delivery_date,
+				subscription_doc.frequency, cint(subscription_doc.repeat_on_day)))
 
 def get_list_context(context=None):
 	from erpnext.controllers.website_list_for_contact import get_list_context
@@ -465,15 +465,14 @@
 				target.po_no = ", ".join(list(set(target_po_no))) if len(target_po_no) > 1 else target_po_no[0]
 			else:
 				target.po_no = source.po_no
-	    
+
 	    #PR : 10861, Author : ashish-greycube & jigneshpshah,  Email:mr.ashish.shah@gmail.com 
 		# Since the credit limit check is bypassed at sales order level, we need to check it at delivery note
-		bypass_credit_limit_check_at_sales_order = frappe.db.get_value("Customer", source.customer, "bypass_credit_limit_check_at_sales_order")
+		bypass_credit_limit_check_at_sales_order = cint(frappe.db.get_value("Customer", source.customer, "bypass_credit_limit_check_at_sales_order"))
 		if bypass_credit_limit_check_at_sales_order == 1:
 			from erpnext.selling.doctype.customer.customer import check_credit_limit
 			check_credit_limit(source.customer, source.company)
 
-
 		target.ignore_pricing_rule = 1
 		target.run_method("set_missing_values")
 		target.run_method("calculate_taxes_and_totals")
@@ -538,7 +537,7 @@
 
 	    #PR : 10861, Author : ashish-greycube & jigneshpshah,  Email:mr.ashish.shah@gmail.com 
 		# Since the credit limit check is bypassed at sales order level, we need to check it at sales invoice
-		bypass_credit_limit_check_at_sales_order = frappe.db.get_value("Customer", source.customer, "bypass_credit_limit_check_at_sales_order")
+		bypass_credit_limit_check_at_sales_order = cint(frappe.db.get_value("Customer", source.customer, "bypass_credit_limit_check_at_sales_order"))
 		if bypass_credit_limit_check_at_sales_order == 1:
 			from erpnext.selling.doctype.customer.customer import check_credit_limit
 			check_credit_limit(source.customer, source.company)
@@ -805,4 +804,4 @@
 			order_by='is_default desc')
 	bom = bom[0].name if bom else None
 
-	return bom
+	return bom
\ No newline at end of file