2018-01-15 13:07:39 +00:00
|
|
|
# Copyright (c) 2017, Frappe and Contributors
|
|
|
|
# License: GNU General Public License v3. See license.txt
|
|
|
|
|
|
|
|
from __future__ import unicode_literals
|
|
|
|
import frappe
|
2018-01-24 12:51:18 +00:00
|
|
|
from erpnext.setup.install import leave_application_workflow
|
2018-01-15 13:07:39 +00:00
|
|
|
|
|
|
|
def execute():
|
|
|
|
frappe.reload_doc("hr", "doctype", "leave_application")
|
|
|
|
frappe.reload_doc("workflow", "doctype", "workflow")
|
2018-01-24 12:51:18 +00:00
|
|
|
leave_application_workflow()
|
2018-01-25 11:36:14 +00:00
|
|
|
if frappe.db.has_column("Leave Application", "status"):
|
|
|
|
frappe.db.sql("""update `tabLeave Application` set workflow_state = status""")
|