mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-13 02:01:21 +00:00
Merge pull request #16108 from KanchanChauhan/indicators-in-leave-applications
[Minor] Indicators in Leave Application
This commit is contained in:
@@ -1,3 +1,10 @@
|
|||||||
frappe.listview_settings['Leave Application'] = {
|
frappe.listview_settings['Leave Application'] = {
|
||||||
add_fields: ["leave_type", "employee", "employee_name", "total_leave_days", "from_date", "to_date"]
|
add_fields: ["leave_type", "employee", "employee_name", "total_leave_days", "from_date", "to_date"],
|
||||||
|
get_indicator: function (doc) {
|
||||||
|
if (doc.status === "Approved") {
|
||||||
|
return [__("Approved"), "green", "status,=,Approved"];
|
||||||
|
} else if (doc.status === "Rejected") {
|
||||||
|
return [__("Rejected"), "red", "status,=,Rejected"];
|
||||||
|
}
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user