mirror of
https://gitea.mueller.network/extern/django-helpdesk.git
synced 2024-11-21 23:43:11 +01:00
Improve code quality
This commit is contained in:
parent
2cb9d382cb
commit
ec603347c7
@ -1676,7 +1676,7 @@ def ticket_dependency_add(request, ticket_id):
|
||||
ticketdependency.ticket = ticket
|
||||
if ticketdependency.ticket != ticketdependency.depends_on:
|
||||
ticketdependency.save()
|
||||
return HttpResponseRedirect(reverse('helpdesk:view', args=[ticket.id]))
|
||||
return redirect(ticket.get_absolute_url())
|
||||
else:
|
||||
form = TicketDependencyForm(ticket)
|
||||
return render(request, 'helpdesk/ticket_dependency_add.html', {
|
||||
@ -1712,7 +1712,7 @@ def ticket_resolves_add(request, ticket_id):
|
||||
ticketdependency.depends_on = depends_on
|
||||
if ticketdependency.ticket != ticketdependency.depends_on:
|
||||
ticketdependency.save()
|
||||
return HttpResponseRedirect(reverse('helpdesk:view', args=[depends_on.id]))
|
||||
return redirect(depends_on.get_absolute_url())
|
||||
else:
|
||||
form = TicketResolvesForm(depends_on)
|
||||
return render(request, 'helpdesk/ticket_resolves_add.html', {
|
||||
|
Loading…
Reference in New Issue
Block a user