Skip to content

Commit

Permalink
Fix user activities api when no task selected
Browse files Browse the repository at this point in the history
  • Loading branch information
dimasciput committed Dec 29, 2023
1 parent 210b8a3 commit da7622a
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions timesheet/api_views/user.py
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,9 @@ def get_task(self, obj):
if task:
return f"{task.project.name} - {task.name}"

if timelog.project:
return f"{timelog.project.name} - {activity.name}"

if activity:
return f"Kartoza - {activity.name}"

Expand Down

0 comments on commit da7622a

Please sign in to comment.