Skip to content

Commit

Permalink
fix(Timesheet): ignore permissions when updating Task and Project (ba…
Browse files Browse the repository at this point in the history
…ckport #45168) (#45170)

* fix(Timesheet): ignore permissions when updating Task and Project (#45168)

(cherry picked from commit 9e760e5)

# Conflicts:
#	erpnext/projects/doctype/timesheet/timesheet.py

* chore: resolve conflicts

---------

Co-authored-by: Raffael Meyer <[email protected]>
  • Loading branch information
mergify[bot] and barredterra authored Jan 13, 2025
1 parent 47c6e5a commit f7448c6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions erpnext/projects/doctype/timesheet/timesheet.py
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ def update_task_and_project(self):
if data.task and data.task not in tasks:
task = frappe.get_doc("Task", data.task)
task.update_time_and_costing()
task.save()
task.save(ignore_permissions=True)
tasks.append(data.task)

if data.project and data.project not in projects:
Expand All @@ -175,7 +175,7 @@ def update_task_and_project(self):
for project in projects:
project_doc = frappe.get_doc("Project", project)
project_doc.update_project()
project_doc.save()
project_doc.save(ignore_permissions=True)

def validate_dates(self):
for data in self.time_logs:
Expand Down

0 comments on commit f7448c6

Please sign in to comment.