From 42b822d53b9a9d447f5dd94cac07f60399c5a3ee Mon Sep 17 00:00:00 2001 From: Deepesh Garg Date: Thu, 16 Jul 2026 15:11:58 +0530 Subject: [PATCH 1/5] fix: Doctype settings map --- .../attendance_(standard).json | 20 ++++++ .../employee_(standard).json | 24 +++++++ .../employee_advance_(standard).json | 20 ++++++ .../employee_checkin_(standard).json | 28 ++++++++ .../exit_interview_(standard).json | 24 +++++++ .../expense_claim_(standard).json | 24 +++++++ .../interview_(standard).json | 36 ++++++++++ .../job_offer_(standard).json | 20 ++++++ .../leave_application_(standard).json | 48 +++++++++++++ .../leave_encashment_(standard).json | 20 ++++++ .../overtime_slip_(standard).json | 24 +++++++ .../shift_assignment_(standard).json | 20 ++++++ .../payroll_entry_(standard).json | 44 ++++++++++++ .../salary_slip_(standard).json | 68 +++++++++++++++++++ 14 files changed, 420 insertions(+) create mode 100644 hrms/hr/doctype_settings_map/attendance_(standard)/attendance_(standard).json create mode 100644 hrms/hr/doctype_settings_map/employee_(standard)/employee_(standard).json create mode 100644 hrms/hr/doctype_settings_map/employee_advance_(standard)/employee_advance_(standard).json create mode 100644 hrms/hr/doctype_settings_map/employee_checkin_(standard)/employee_checkin_(standard).json create mode 100644 hrms/hr/doctype_settings_map/exit_interview_(standard)/exit_interview_(standard).json create mode 100644 hrms/hr/doctype_settings_map/expense_claim_(standard)/expense_claim_(standard).json create mode 100644 hrms/hr/doctype_settings_map/interview_(standard)/interview_(standard).json create mode 100644 hrms/hr/doctype_settings_map/job_offer_(standard)/job_offer_(standard).json create mode 100644 hrms/hr/doctype_settings_map/leave_application_(standard)/leave_application_(standard).json create mode 100644 hrms/hr/doctype_settings_map/leave_encashment_(standard)/leave_encashment_(standard).json create mode 100644 hrms/hr/doctype_settings_map/overtime_slip_(standard)/overtime_slip_(standard).json create mode 100644 hrms/hr/doctype_settings_map/shift_assignment_(standard)/shift_assignment_(standard).json create mode 100644 hrms/payroll/doctype_settings_map/payroll_entry_(standard)/payroll_entry_(standard).json create mode 100644 hrms/payroll/doctype_settings_map/salary_slip_(standard)/salary_slip_(standard).json diff --git a/hrms/hr/doctype_settings_map/attendance_(standard)/attendance_(standard).json b/hrms/hr/doctype_settings_map/attendance_(standard)/attendance_(standard).json new file mode 100644 index 0000000000..414fce50f8 --- /dev/null +++ b/hrms/hr/doctype_settings_map/attendance_(standard)/attendance_(standard).json @@ -0,0 +1,20 @@ +{ + "applies_to_doctype": "Attendance", + "creation": "2026-07-16 00:00:00.000000", + "docstatus": 0, + "doctype": "DocType Settings Map", + "idx": 0, + "is_active": 1, + "is_standard": 1, + "mappings": [ + { + "setting_field": "standard_working_hours", + "settings_doctype": "HR Settings" + } + ], + "modified": "2026-07-16 00:00:00.000000", + "modified_by": "Administrator", + "module": "HR", + "name": "Attendance (Standard)", + "owner": "Administrator" +} diff --git a/hrms/hr/doctype_settings_map/employee_(standard)/employee_(standard).json b/hrms/hr/doctype_settings_map/employee_(standard)/employee_(standard).json new file mode 100644 index 0000000000..198beedda1 --- /dev/null +++ b/hrms/hr/doctype_settings_map/employee_(standard)/employee_(standard).json @@ -0,0 +1,24 @@ +{ + "applies_to_doctype": "Employee", + "creation": "2026-07-16 00:00:00.000000", + "docstatus": 0, + "doctype": "DocType Settings Map", + "idx": 0, + "is_active": 1, + "is_standard": 1, + "mappings": [ + { + "setting_field": "retirement_age", + "settings_doctype": "HR Settings" + }, + { + "setting_field": "emp_created_by", + "settings_doctype": "HR Settings" + } + ], + "modified": "2026-07-16 00:00:00.000000", + "modified_by": "Administrator", + "module": "HR", + "name": "Employee (Standard)", + "owner": "Administrator" +} diff --git a/hrms/hr/doctype_settings_map/employee_advance_(standard)/employee_advance_(standard).json b/hrms/hr/doctype_settings_map/employee_advance_(standard)/employee_advance_(standard).json new file mode 100644 index 0000000000..464fe346f6 --- /dev/null +++ b/hrms/hr/doctype_settings_map/employee_advance_(standard)/employee_advance_(standard).json @@ -0,0 +1,20 @@ +{ + "applies_to_doctype": "Employee Advance", + "creation": "2026-07-16 00:00:00.000000", + "docstatus": 0, + "doctype": "DocType Settings Map", + "idx": 0, + "is_active": 1, + "is_standard": 1, + "mappings": [ + { + "setting_field": "unlink_payment_on_cancellation_of_employee_advance", + "settings_doctype": "HR Settings" + } + ], + "modified": "2026-07-16 00:00:00.000000", + "modified_by": "Administrator", + "module": "HR", + "name": "Employee Advance (Standard)", + "owner": "Administrator" +} diff --git a/hrms/hr/doctype_settings_map/employee_checkin_(standard)/employee_checkin_(standard).json b/hrms/hr/doctype_settings_map/employee_checkin_(standard)/employee_checkin_(standard).json new file mode 100644 index 0000000000..781a44e5e4 --- /dev/null +++ b/hrms/hr/doctype_settings_map/employee_checkin_(standard)/employee_checkin_(standard).json @@ -0,0 +1,28 @@ +{ + "applies_to_doctype": "Employee Checkin", + "creation": "2026-07-16 00:00:00.000000", + "docstatus": 0, + "doctype": "DocType Settings Map", + "idx": 0, + "is_active": 1, + "is_standard": 1, + "mappings": [ + { + "setting_field": "allow_employee_checkin_from_mobile_app", + "settings_doctype": "HR Settings" + }, + { + "setting_field": "allow_geolocation_tracking", + "settings_doctype": "HR Settings" + }, + { + "setting_field": "standard_working_hours", + "settings_doctype": "HR Settings" + } + ], + "modified": "2026-07-16 00:00:00.000000", + "modified_by": "Administrator", + "module": "HR", + "name": "Employee Checkin (Standard)", + "owner": "Administrator" +} diff --git a/hrms/hr/doctype_settings_map/exit_interview_(standard)/exit_interview_(standard).json b/hrms/hr/doctype_settings_map/exit_interview_(standard)/exit_interview_(standard).json new file mode 100644 index 0000000000..77cb2b864b --- /dev/null +++ b/hrms/hr/doctype_settings_map/exit_interview_(standard)/exit_interview_(standard).json @@ -0,0 +1,24 @@ +{ + "applies_to_doctype": "Exit Interview", + "creation": "2026-07-16 00:00:00.000000", + "docstatus": 0, + "doctype": "DocType Settings Map", + "idx": 0, + "is_active": 1, + "is_standard": 1, + "mappings": [ + { + "setting_field": "exit_questionnaire_web_form", + "settings_doctype": "HR Settings" + }, + { + "setting_field": "exit_questionnaire_notification_template", + "settings_doctype": "HR Settings" + } + ], + "modified": "2026-07-16 00:00:00.000000", + "modified_by": "Administrator", + "module": "HR", + "name": "Exit Interview (Standard)", + "owner": "Administrator" +} diff --git a/hrms/hr/doctype_settings_map/expense_claim_(standard)/expense_claim_(standard).json b/hrms/hr/doctype_settings_map/expense_claim_(standard)/expense_claim_(standard).json new file mode 100644 index 0000000000..0ab6bb5034 --- /dev/null +++ b/hrms/hr/doctype_settings_map/expense_claim_(standard)/expense_claim_(standard).json @@ -0,0 +1,24 @@ +{ + "applies_to_doctype": "Expense Claim", + "creation": "2026-07-16 00:00:00.000000", + "docstatus": 0, + "doctype": "DocType Settings Map", + "idx": 0, + "is_active": 1, + "is_standard": 1, + "mappings": [ + { + "setting_field": "expense_approver_mandatory_in_expense_claim", + "settings_doctype": "HR Settings" + }, + { + "setting_field": "prevent_self_expense_approval", + "settings_doctype": "HR Settings" + } + ], + "modified": "2026-07-16 00:00:00.000000", + "modified_by": "Administrator", + "module": "HR", + "name": "Expense Claim (Standard)", + "owner": "Administrator" +} diff --git a/hrms/hr/doctype_settings_map/interview_(standard)/interview_(standard).json b/hrms/hr/doctype_settings_map/interview_(standard)/interview_(standard).json new file mode 100644 index 0000000000..31da72dfcb --- /dev/null +++ b/hrms/hr/doctype_settings_map/interview_(standard)/interview_(standard).json @@ -0,0 +1,36 @@ +{ + "applies_to_doctype": "Interview", + "creation": "2026-07-16 00:00:00.000000", + "docstatus": 0, + "doctype": "DocType Settings Map", + "idx": 0, + "is_active": 1, + "is_standard": 1, + "mappings": [ + { + "setting_field": "send_interview_reminder", + "settings_doctype": "HR Settings" + }, + { + "setting_field": "send_interview_feedback_reminder", + "settings_doctype": "HR Settings" + }, + { + "setting_field": "remind_before", + "settings_doctype": "HR Settings" + }, + { + "setting_field": "interview_reminder_template", + "settings_doctype": "HR Settings" + }, + { + "setting_field": "feedback_reminder_notification_template", + "settings_doctype": "HR Settings" + } + ], + "modified": "2026-07-16 00:00:00.000000", + "modified_by": "Administrator", + "module": "HR", + "name": "Interview (Standard)", + "owner": "Administrator" +} diff --git a/hrms/hr/doctype_settings_map/job_offer_(standard)/job_offer_(standard).json b/hrms/hr/doctype_settings_map/job_offer_(standard)/job_offer_(standard).json new file mode 100644 index 0000000000..093f8bde39 --- /dev/null +++ b/hrms/hr/doctype_settings_map/job_offer_(standard)/job_offer_(standard).json @@ -0,0 +1,20 @@ +{ + "applies_to_doctype": "Job Offer", + "creation": "2026-07-16 00:00:00.000000", + "docstatus": 0, + "doctype": "DocType Settings Map", + "idx": 0, + "is_active": 1, + "is_standard": 1, + "mappings": [ + { + "setting_field": "check_vacancies", + "settings_doctype": "HR Settings" + } + ], + "modified": "2026-07-16 00:00:00.000000", + "modified_by": "Administrator", + "module": "HR", + "name": "Job Offer (Standard)", + "owner": "Administrator" +} diff --git a/hrms/hr/doctype_settings_map/leave_application_(standard)/leave_application_(standard).json b/hrms/hr/doctype_settings_map/leave_application_(standard)/leave_application_(standard).json new file mode 100644 index 0000000000..8bd96b12f5 --- /dev/null +++ b/hrms/hr/doctype_settings_map/leave_application_(standard)/leave_application_(standard).json @@ -0,0 +1,48 @@ +{ + "applies_to_doctype": "Leave Application", + "creation": "2026-07-16 00:00:00.000000", + "docstatus": 0, + "doctype": "DocType Settings Map", + "idx": 0, + "is_active": 1, + "is_standard": 1, + "mappings": [ + { + "setting_field": "leave_approver_mandatory_in_leave_application", + "settings_doctype": "HR Settings" + }, + { + "setting_field": "prevent_self_leave_approval", + "settings_doctype": "HR Settings" + }, + { + "setting_field": "restrict_backdated_leave_application", + "settings_doctype": "HR Settings" + }, + { + "setting_field": "role_allowed_to_create_backdated_leave_application", + "settings_doctype": "HR Settings" + }, + { + "setting_field": "show_leaves_of_all_department_members_in_calendar", + "settings_doctype": "HR Settings" + }, + { + "setting_field": "send_leave_notification", + "settings_doctype": "HR Settings" + }, + { + "setting_field": "leave_approval_notification_template", + "settings_doctype": "HR Settings" + }, + { + "setting_field": "leave_status_notification_template", + "settings_doctype": "HR Settings" + } + ], + "modified": "2026-07-16 00:00:00.000000", + "modified_by": "Administrator", + "module": "HR", + "name": "Leave Application (Standard)", + "owner": "Administrator" +} diff --git a/hrms/hr/doctype_settings_map/leave_encashment_(standard)/leave_encashment_(standard).json b/hrms/hr/doctype_settings_map/leave_encashment_(standard)/leave_encashment_(standard).json new file mode 100644 index 0000000000..f515e0a8b5 --- /dev/null +++ b/hrms/hr/doctype_settings_map/leave_encashment_(standard)/leave_encashment_(standard).json @@ -0,0 +1,20 @@ +{ + "applies_to_doctype": "Leave Encashment", + "creation": "2026-07-16 00:00:00.000000", + "docstatus": 0, + "doctype": "DocType Settings Map", + "idx": 0, + "is_active": 1, + "is_standard": 1, + "mappings": [ + { + "setting_field": "auto_leave_encashment", + "settings_doctype": "HR Settings" + } + ], + "modified": "2026-07-16 00:00:00.000000", + "modified_by": "Administrator", + "module": "HR", + "name": "Leave Encashment (Standard)", + "owner": "Administrator" +} diff --git a/hrms/hr/doctype_settings_map/overtime_slip_(standard)/overtime_slip_(standard).json b/hrms/hr/doctype_settings_map/overtime_slip_(standard)/overtime_slip_(standard).json new file mode 100644 index 0000000000..e19a300a0e --- /dev/null +++ b/hrms/hr/doctype_settings_map/overtime_slip_(standard)/overtime_slip_(standard).json @@ -0,0 +1,24 @@ +{ + "applies_to_doctype": "Overtime Slip", + "creation": "2026-07-16 00:00:00.000000", + "docstatus": 0, + "doctype": "DocType Settings Map", + "idx": 0, + "is_active": 1, + "is_standard": 1, + "mappings": [ + { + "setting_field": "create_overtime_slip", + "settings_doctype": "Payroll Settings" + }, + { + "setting_field": "standard_working_hours", + "settings_doctype": "HR Settings" + } + ], + "modified": "2026-07-16 00:00:00.000000", + "modified_by": "Administrator", + "module": "HR", + "name": "Overtime Slip (Standard)", + "owner": "Administrator" +} diff --git a/hrms/hr/doctype_settings_map/shift_assignment_(standard)/shift_assignment_(standard).json b/hrms/hr/doctype_settings_map/shift_assignment_(standard)/shift_assignment_(standard).json new file mode 100644 index 0000000000..1a2ad57c22 --- /dev/null +++ b/hrms/hr/doctype_settings_map/shift_assignment_(standard)/shift_assignment_(standard).json @@ -0,0 +1,20 @@ +{ + "applies_to_doctype": "Shift Assignment", + "creation": "2026-07-16 00:00:00.000000", + "docstatus": 0, + "doctype": "DocType Settings Map", + "idx": 0, + "is_active": 1, + "is_standard": 1, + "mappings": [ + { + "setting_field": "allow_multiple_shift_assignments", + "settings_doctype": "HR Settings" + } + ], + "modified": "2026-07-16 00:00:00.000000", + "modified_by": "Administrator", + "module": "HR", + "name": "Shift Assignment (Standard)", + "owner": "Administrator" +} diff --git a/hrms/payroll/doctype_settings_map/payroll_entry_(standard)/payroll_entry_(standard).json b/hrms/payroll/doctype_settings_map/payroll_entry_(standard)/payroll_entry_(standard).json new file mode 100644 index 0000000000..f934c5c1c5 --- /dev/null +++ b/hrms/payroll/doctype_settings_map/payroll_entry_(standard)/payroll_entry_(standard).json @@ -0,0 +1,44 @@ +{ + "applies_to_doctype": "Payroll Entry", + "creation": "2026-07-16 00:00:00.000000", + "docstatus": 0, + "doctype": "DocType Settings Map", + "idx": 0, + "is_active": 1, + "is_standard": 1, + "mappings": [ + { + "setting_field": "payroll_based_on", + "settings_doctype": "Payroll Settings" + }, + { + "setting_field": "include_holidays_in_total_working_days", + "settings_doctype": "Payroll Settings" + }, + { + "setting_field": "consider_unmarked_attendance_as", + "settings_doctype": "Payroll Settings" + }, + { + "setting_field": "consider_marked_attendance_on_holidays", + "settings_doctype": "Payroll Settings" + }, + { + "setting_field": "email_salary_slip_to_employee", + "settings_doctype": "Payroll Settings" + }, + { + "setting_field": "process_payroll_accounting_entry_based_on_employee", + "settings_doctype": "Payroll Settings" + }, + { + "setting_field": "create_overtime_slip", + "settings_doctype": "Payroll Settings" + } + ], + "modified": "2026-07-16 00:00:00.000000", + "modified_by": "Administrator", + "module": "Payroll", + "name": "Payroll Entry (Standard)", + "owner": "Administrator" +} diff --git a/hrms/payroll/doctype_settings_map/salary_slip_(standard)/salary_slip_(standard).json b/hrms/payroll/doctype_settings_map/salary_slip_(standard)/salary_slip_(standard).json new file mode 100644 index 0000000000..3f432ff100 --- /dev/null +++ b/hrms/payroll/doctype_settings_map/salary_slip_(standard)/salary_slip_(standard).json @@ -0,0 +1,68 @@ +{ + "applies_to_doctype": "Salary Slip", + "creation": "2026-07-16 00:00:00.000000", + "docstatus": 0, + "doctype": "DocType Settings Map", + "idx": 0, + "is_active": 1, + "is_standard": 1, + "mappings": [ + { + "setting_field": "payroll_based_on", + "settings_doctype": "Payroll Settings" + }, + { + "setting_field": "include_holidays_in_total_working_days", + "settings_doctype": "Payroll Settings" + }, + { + "setting_field": "consider_unmarked_attendance_as", + "settings_doctype": "Payroll Settings" + }, + { + "setting_field": "consider_marked_attendance_on_holidays", + "settings_doctype": "Payroll Settings" + }, + { + "setting_field": "max_working_hours_against_timesheet", + "settings_doctype": "Payroll Settings" + }, + { + "setting_field": "daily_wages_fraction_for_half_day", + "settings_doctype": "Payroll Settings" + }, + { + "setting_field": "disable_rounded_total", + "settings_doctype": "Payroll Settings" + }, + { + "setting_field": "show_leave_balances_in_salary_slip", + "settings_doctype": "Payroll Settings" + }, + { + "setting_field": "email_salary_slip_to_employee", + "settings_doctype": "Payroll Settings" + }, + { + "setting_field": "encrypt_salary_slips_in_emails", + "settings_doctype": "Payroll Settings" + }, + { + "setting_field": "password_policy", + "settings_doctype": "Payroll Settings" + }, + { + "setting_field": "process_payroll_accounting_entry_based_on_employee", + "settings_doctype": "Payroll Settings" + }, + { + "setting_field": "mandatory_benefit_application", + "settings_doctype": "Payroll Settings" + } + ], + "modified": "2026-07-16 00:00:00.000000", + "modified_by": "Administrator", + "module": "Payroll", + "name": "Salary Slip (Standard)", + "owner": "Administrator" +} From 9e5be5659f615f7031acb39a984d58ad5cb4d590 Mon Sep 17 00:00:00 2001 From: pratheep-bit Date: Tue, 21 Jul 2026 11:15:12 +0530 Subject: [PATCH 2/5] fix(leave_ledger_entry): ignore cancelled allocation in expire_allocation --- hrms/hr/doctype/leave_ledger_entry/leave_ledger_entry.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/hrms/hr/doctype/leave_ledger_entry/leave_ledger_entry.py b/hrms/hr/doctype/leave_ledger_entry/leave_ledger_entry.py index 3f24022959..a2beda3446 100644 --- a/hrms/hr/doctype/leave_ledger_entry/leave_ledger_entry.py +++ b/hrms/hr/doctype/leave_ledger_entry/leave_ledger_entry.py @@ -227,6 +227,9 @@ def expire_allocation(allocation: str | Document | frappe._dict, expiry_date: da allocation = json.loads(allocation) allocation = frappe.get_doc("Leave Allocation", allocation["name"]) + if getattr(allocation, "docstatus", 0) == 2: + return + frappe.has_permission("Leave Allocation", "write", allocation.name, throw=True) leaves = get_remaining_leaves(allocation) From 84e408b28932f80b89b97bb671e3f5f1d2c19220 Mon Sep 17 00:00:00 2001 From: pratheep-bit Date: Tue, 21 Jul 2026 11:15:12 +0530 Subject: [PATCH 3/5] fix(payroll_entry): harden create_salary_slips_for_employees against mass assignment --- .../doctype/payroll_entry/payroll_entry.py | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/hrms/payroll/doctype/payroll_entry/payroll_entry.py b/hrms/payroll/doctype/payroll_entry/payroll_entry.py index b9a4b82d8e..29f4da251e 100644 --- a/hrms/payroll/doctype/payroll_entry/payroll_entry.py +++ b/hrms/payroll/doctype/payroll_entry/payroll_entry.py @@ -1605,8 +1605,23 @@ def create_salary_slips_for_employees(employees, args, publish_progress=True): employees = list(set(employees) - set(salary_slips_exist_for)) for emp in employees: - args.update({"doctype": "Salary Slip", "employee": emp}) - frappe.get_doc(args).insert() + slip_args = { + "doctype": "Salary Slip", + "employee": emp, + "salary_slip_based_on_timesheet": args.get("salary_slip_based_on_timesheet"), + "payroll_frequency": args.get("payroll_frequency"), + "start_date": args.get("start_date"), + "end_date": args.get("end_date"), + "company": args.get("company"), + "posting_date": args.get("posting_date"), + "deduct_tax_for_unsubmitted_tax_exemption_proof": args.get( + "deduct_tax_for_unsubmitted_tax_exemption_proof" + ), + "payroll_entry": args.get("payroll_entry"), + "exchange_rate": args.get("exchange_rate"), + "currency": args.get("currency"), + } + frappe.get_doc(slip_args).insert() count += 1 if publish_progress: From abb8d795b13cac6888f573dc16b55e4773cd302a Mon Sep 17 00:00:00 2001 From: pratheep-bit Date: Tue, 21 Jul 2026 11:15:11 +0530 Subject: [PATCH 4/5] fix(vehicle_expenses): apply docstatus=1 filter to get_service_expense --- .../vehicle_expenses/vehicle_expenses.py | 22 ++++++++++--------- 1 file changed, 12 insertions(+), 10 deletions(-) diff --git a/hrms/hr/report/vehicle_expenses/vehicle_expenses.py b/hrms/hr/report/vehicle_expenses/vehicle_expenses.py index 8fec0140ab..2d4f69e076 100644 --- a/hrms/hr/report/vehicle_expenses/vehicle_expenses.py +++ b/hrms/hr/report/vehicle_expenses/vehicle_expenses.py @@ -118,16 +118,18 @@ def get_period_dates(filters): def get_service_expense(logname): - expense_amount = frappe.db.sql( - """ - SELECT sum(expense_amount) - FROM - `tabVehicle Log` log, `tabVehicle Service` service - WHERE - service.parent=log.name and log.name=%s - """, - logname, - ) + from frappe.query_builder.functions import Sum + + log = frappe.qb.DocType("Vehicle Log") + service = frappe.qb.DocType("Vehicle Service") + + expense_amount = ( + frappe.qb.from_(log) + .inner_join(service) + .on(service.parent == log.name) + .select(Sum(service.expense_amount)) + .where((log.name == logname) & (log.docstatus == 1)) + ).run() return flt(expense_amount[0][0]) if expense_amount else 0.0 From bcc53de7ff0861fb5eb1fd85e18c557fc4979b31 Mon Sep 17 00:00:00 2001 From: Mohsin Akhtar <167299936+akhtarmohsin@users.noreply.github.com> Date: Tue, 21 Jul 2026 16:42:52 +0530 Subject: [PATCH 5/5] fix: correct salary slip naming when created via data import default_series was set in __init__ before field values were populated, causing employee to be None and generating names like Sal Slip/None/00001. Converting it to a property fixes the issue by reading employee lazily. --- hrms/payroll/doctype/salary_slip/salary_slip.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/hrms/payroll/doctype/salary_slip/salary_slip.py b/hrms/payroll/doctype/salary_slip/salary_slip.py index c3ea9a9b61..350ff39187 100644 --- a/hrms/payroll/doctype/salary_slip/salary_slip.py +++ b/hrms/payroll/doctype/salary_slip/salary_slip.py @@ -150,9 +150,12 @@ class SalarySlip(TransactionBase): def __init__(self, *args, **kwargs): super().__init__(*args, **kwargs) - self.default_series = f"Sal Slip/{self.employee}/.#####" self.whitelisted_globals = COMPONENT_EVAL_GLOBALS.copy() + @property + def default_series(self): + return f"Sal Slip/{self.employee}/.#####" + def autoname(self): if not self.has_custom_naming_series: self.name = make_autoname(self.default_series)