Browse Source

fix: 修复工单发邮件及授权资产备注信息修改

pull/7065/head
feng626 3 years ago
parent
commit
52889cb67a
  1. 2
      apps/tickets/handler/apply_application.py
  2. 2
      apps/tickets/handler/apply_asset.py
  3. 4
      apps/tickets/handler/base.py

2
apps/tickets/handler/apply_application.py

@ -84,7 +84,7 @@ class Handler(BaseHandler):
).format( ).format(
self.ticket.title, self.ticket.title,
self.ticket.applicant_display, self.ticket.applicant_display,
str(self.ticket.processor), ','.join([i['processor_display'] for i in self.ticket.process_map]),
str(self.ticket.id) str(self.ticket.id)
) )
permissions_data = { permissions_data = {

2
apps/tickets/handler/apply_asset.py

@ -77,7 +77,7 @@ class Handler(BaseHandler):
).format( ).format(
self.ticket.title, self.ticket.title,
self.ticket.applicant_display, self.ticket.applicant_display,
str(self.ticket.processor), ','.join([i['processor_display'] for i in self.ticket.process_map]),
str(self.ticket.id) str(self.ticket.id)
) )

4
apps/tickets/handler/base.py

@ -23,16 +23,18 @@ class BaseHandler(object):
def _on_approve(self): def _on_approve(self):
if self.ticket.approval_step != len(self.ticket.process_map): if self.ticket.approval_step != len(self.ticket.process_map):
self._send_processed_mail_to_applicant(self.ticket.processor)
self.ticket.approval_step += 1 self.ticket.approval_step += 1
self.ticket.create_related_node() self.ticket.create_related_node()
self._send_applied_mail_to_assignees() self._send_applied_mail_to_assignees()
is_finished = False is_finished = False
else: else:
self._send_processed_mail_to_applicant(self.ticket.processor)
self.ticket.set_state_approve() self.ticket.set_state_approve()
self.ticket.set_status_closed() self.ticket.set_status_closed()
is_finished = True is_finished = True
self.__on_process(self.ticket.processor) self.ticket.save()
return is_finished return is_finished
def _on_reject(self): def _on_reject(self):

Loading…
Cancel
Save