Browse Source

Merge pull request #7394 from jumpserver/pr@dev@ticket_filter_bug

perf: ticket filter
pull/7397/head
feng626 3 years ago committed by GitHub
parent
commit
facc231e3f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      apps/tickets/filters.py
  2. 2
      apps/tickets/handler/base.py

2
apps/tickets/filters.py

@ -10,7 +10,7 @@ class TicketFilter(BaseFilterSet):
class Meta:
model = Ticket
fields = (
'id', 'title', 'type', 'status', 'applicant', 'assignees__id',
'id', 'title', 'type', 'status', 'state', 'applicant', 'assignees__id',
'applicant_display',
)

2
apps/tickets/handler/base.py

@ -29,9 +29,9 @@ class BaseHandler(object):
self._send_applied_mail_to_assignees()
is_finished = False
else:
self._send_processed_mail_to_applicant(self.ticket.processor)
self.ticket.set_state_approve()
self.ticket.set_status_closed()
self._send_processed_mail_to_applicant(self.ticket.processor)
is_finished = True
self.ticket.save()

Loading…
Cancel
Save