Merge pull request #14162 from rohitwaghchaure/permissions_issue_leave_application
[Fix] Permission issue while saving leave application
This commit is contained in:
commit
37da7d7d05
@ -126,6 +126,7 @@ class LeaveApplication(Document):
|
|||||||
doc.company = self.company
|
doc.company = self.company
|
||||||
doc.status = "On Leave"
|
doc.status = "On Leave"
|
||||||
doc.leave_type = self.leave_type
|
doc.leave_type = self.leave_type
|
||||||
|
doc.insert(ignore_permissions=True)
|
||||||
doc.submit()
|
doc.submit()
|
||||||
else:
|
else:
|
||||||
doc = frappe.new_doc("Attendance")
|
doc = frappe.new_doc("Attendance")
|
||||||
@ -134,6 +135,7 @@ class LeaveApplication(Document):
|
|||||||
doc.company = self.company
|
doc.company = self.company
|
||||||
doc.status = "Half Day"
|
doc.status = "Half Day"
|
||||||
doc.leave_type = self.leave_type
|
doc.leave_type = self.leave_type
|
||||||
|
doc.insert(ignore_permissions=True)
|
||||||
doc.submit()
|
doc.submit()
|
||||||
|
|
||||||
def validate_salary_processed_days(self):
|
def validate_salary_processed_days(self):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user