mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-03 20:29:09 +00:00
fix: Leave application status (#23043)
* fix: leave application status update fix * fix:adding patch
This commit is contained in:
@@ -1,5 +1,4 @@
|
|||||||
{
|
{
|
||||||
"actions": [],
|
|
||||||
"allow_import": 1,
|
"allow_import": 1,
|
||||||
"autoname": "naming_series:",
|
"autoname": "naming_series:",
|
||||||
"creation": "2013-02-20 11:18:11",
|
"creation": "2013-02-20 11:18:11",
|
||||||
@@ -167,6 +166,7 @@
|
|||||||
"fieldtype": "Column Break"
|
"fieldtype": "Column Break"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
"allow_on_submit": 1,
|
||||||
"default": "Open",
|
"default": "Open",
|
||||||
"fieldname": "status",
|
"fieldname": "status",
|
||||||
"fieldtype": "Select",
|
"fieldtype": "Select",
|
||||||
@@ -246,9 +246,8 @@
|
|||||||
"icon": "fa fa-calendar",
|
"icon": "fa fa-calendar",
|
||||||
"idx": 1,
|
"idx": 1,
|
||||||
"is_submittable": 1,
|
"is_submittable": 1,
|
||||||
"links": [],
|
|
||||||
"max_attachments": 3,
|
"max_attachments": 3,
|
||||||
"modified": "2020-03-10 22:40:43.487721",
|
"modified": "2020-08-13 17:22:44.832397",
|
||||||
"modified_by": "Administrator",
|
"modified_by": "Administrator",
|
||||||
"module": "HR",
|
"module": "HR",
|
||||||
"name": "Leave Application",
|
"name": "Leave Application",
|
||||||
@@ -333,4 +332,4 @@
|
|||||||
"sort_order": "DESC",
|
"sort_order": "DESC",
|
||||||
"timeline_field": "employee",
|
"timeline_field": "employee",
|
||||||
"title_field": "employee_name"
|
"title_field": "employee_name"
|
||||||
}
|
}
|
||||||
@@ -676,3 +676,4 @@ erpnext.patches.v12_0.move_due_advance_amount_to_pending_amount
|
|||||||
erpnext.patches.v12_0.set_multi_uom_in_rfq
|
erpnext.patches.v12_0.set_multi_uom_in_rfq
|
||||||
erpnext.patches.v12_0.update_state_code_for_daman_and_diu
|
erpnext.patches.v12_0.update_state_code_for_daman_and_diu
|
||||||
erpnext.patches.v12_0.rename_lost_reason_detail
|
erpnext.patches.v12_0.rename_lost_reason_detail
|
||||||
|
erpnext.patches.v12_0.update_leave_application_status
|
||||||
|
|||||||
10
erpnext/patches/v12_0/update_leave_application_status.py
Normal file
10
erpnext/patches/v12_0/update_leave_application_status.py
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
from __future__ import unicode_literals
|
||||||
|
import frappe
|
||||||
|
|
||||||
|
def execute():
|
||||||
|
# frappe.reload_doc('HR', 'doctype', 'leave_application')
|
||||||
|
frappe.db.sql("""
|
||||||
|
UPDATE `tabLeave Application` SET
|
||||||
|
status = 'Cancelled'
|
||||||
|
WHERE status = 'Approved' and docstatus = 2
|
||||||
|
""")
|
||||||
Reference in New Issue
Block a user