-
Notifications
You must be signed in to change notification settings - Fork 831
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: status fields becomes read only if self leave approval is prevented
refactor: used onload to check hr settings refactor: hr setting name changed for readability
- Loading branch information
1 parent
8374c75
commit 52b5e1f
Showing
4 changed files
with
61 additions
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -968,7 +968,7 @@ def test_leave_approver_perms(self): | |
employee.save() | ||
|
||
def test_self_leave_approval_allowed(self): | ||
frappe.db.set_single_value("HR Settings", "allow_self_leave_approval", 1) | ||
frappe.db.set_single_value("HR Settings", "prevent_self_leave_approval", 0) | ||
|
||
leave_approver = "[email protected]" | ||
make_employee(leave_approver, "_Test Company") | ||
|
@@ -1006,7 +1006,7 @@ def test_self_leave_approval_allowed(self): | |
frappe.set_user("Administrator") | ||
|
||
def test_self_leave_approval_not_allowed(self): | ||
frappe.db.set_single_value("HR Settings", "allow_self_leave_approval", 0) | ||
frappe.db.set_single_value("HR Settings", "prevent_self_leave_approval", 1) | ||
|
||
leave_approver = "[email protected]" | ||
make_employee(leave_approver, "_Test Company") | ||
|