mirror of
https://gitea.mueller.network/extern/django-helpdesk.git
synced 2024-11-24 17:04:25 +01:00
Unassigned tickets lookup foix when teams is disabled.
This commit is contained in:
parent
9147cb16d5
commit
9195e4b738
@ -151,16 +151,19 @@ def dashboard(request):
|
|||||||
# closed & resolved tickets, assigned to current user
|
# closed & resolved tickets, assigned to current user
|
||||||
tickets_closed_resolved = Ticket.objects.select_related('queue').filter(
|
tickets_closed_resolved = Ticket.objects.select_related('queue').filter(
|
||||||
assigned_to=request.user,
|
assigned_to=request.user,
|
||||||
status__in=[Ticket.CLOSED_STATUS, Ticket.RESOLVED_STATUS])
|
status__in=[Ticket.CLOSED_STATUS, Ticket.RESOLVED_STATUS]
|
||||||
|
)
|
||||||
|
|
||||||
user_queues = huser.get_queues()
|
user_queues = huser.get_queues()
|
||||||
|
|
||||||
unassigned_tickets = active_tickets.filter(
|
unassigned_tickets = active_tickets.filter(
|
||||||
assigned_to__isnull=True,
|
assigned_to__isnull=True,
|
||||||
kbitem__isnull=True,
|
|
||||||
queue__in=user_queues
|
queue__in=user_queues
|
||||||
)
|
)
|
||||||
|
kbitems = None
|
||||||
|
# Teams mode uses assignment via knowledge base items so exclude tickets assigned to KB items
|
||||||
|
if helpdesk_settings.HELPDESK_TEAMS_MODE_ENABLED:
|
||||||
|
unassigned_tickets = unassigned_tickets.filter(kbitem__isnull=True)
|
||||||
kbitems = huser.get_assigned_kb_items()
|
kbitems = huser.get_assigned_kb_items()
|
||||||
|
|
||||||
# all tickets, reported by current user
|
# all tickets, reported by current user
|
||||||
|
Loading…
Reference in New Issue
Block a user