fix(leave-type): Drop column max_days_allowed (#15642)

This commit is contained in:
Shreya Shah 2018-10-10 14:48:49 +05:30 committed by Nabin Hait
parent 4cfff7829b
commit dd87e0f1e2
2 changed files with 7 additions and 0 deletions

View File

@ -568,4 +568,5 @@ erpnext.patches.v11_0.remove_land_unit_icon
erpnext.patches.v11_0.add_default_dispatch_notification_template
erpnext.patches.v11_0.add_market_segments
erpnext.patches.v11_0.add_sales_stages
erpnext.patches.v11_0.drop_column_max_days_allowed
erpnext.patches.v11_0.change_healthcare_desktop_icons

View File

@ -0,0 +1,6 @@
import frappe
def execute():
if frappe.db.exists("DocType", "Leave Type"):
if 'max_days_allowed' in frappe.db.get_table_columns("Leave Type"):
frappe.db.sql("alter table `tabLeave Type` drop column max_days_allowed")