mirror of
https://github.com/django-helpdesk/django-helpdesk.git
synced 2025-06-20 09:37:48 +02:00
Allow multiple e-mails to be entered for the queue CC email addresses. Separate with a comma. Closes GH-49.
This commit is contained in:
parent
b31068caa9
commit
b5da29dcfe
@ -102,7 +102,10 @@ def send_templated_mail(template_name, email_context, recipients, sender=None, b
|
|||||||
"{{ ticket.ticket }} {{ ticket.title|safe }} %s" % t.subject
|
"{{ ticket.ticket }} {{ ticket.title|safe }} %s" % t.subject
|
||||||
).render(context)
|
).render(context)
|
||||||
|
|
||||||
if type(recipients) != list:
|
if type(recipients) == str:
|
||||||
|
if recipients.find(','):
|
||||||
|
recipients = recipients.split(',')
|
||||||
|
elif type(recipients) != list:
|
||||||
recipients = [recipients,]
|
recipients = [recipients,]
|
||||||
|
|
||||||
msg = EmailMultiAlternatives( subject_part,
|
msg = EmailMultiAlternatives( subject_part,
|
||||||
|
@ -80,21 +80,25 @@ class Queue(models.Model):
|
|||||||
'increase their priority? Set to 0 for no escalation.'),
|
'increase their priority? Set to 0 for no escalation.'),
|
||||||
)
|
)
|
||||||
|
|
||||||
new_ticket_cc = models.EmailField(
|
new_ticket_cc = models.CharField(
|
||||||
_('New Ticket CC Address'),
|
_('New Ticket CC Address'),
|
||||||
blank=True,
|
blank=True,
|
||||||
null=True,
|
null=True,
|
||||||
|
max_length=200,
|
||||||
help_text=_('If an e-mail address is entered here, then it will '
|
help_text=_('If an e-mail address is entered here, then it will '
|
||||||
'receive notification of all new tickets created for this queue'),
|
'receive notification of all new tickets created for this queue. '
|
||||||
|
'Enter a comma between multiple e-mail addresses.'),
|
||||||
)
|
)
|
||||||
|
|
||||||
updated_ticket_cc = models.EmailField(
|
updated_ticket_cc = models.CharField(
|
||||||
_('Updated Ticket CC Address'),
|
_('Updated Ticket CC Address'),
|
||||||
blank=True,
|
blank=True,
|
||||||
null=True,
|
null=True,
|
||||||
|
max_length=200,
|
||||||
help_text=_('If an e-mail address is entered here, then it will '
|
help_text=_('If an e-mail address is entered here, then it will '
|
||||||
'receive notification of all activity (new tickets, closed '
|
'receive notification of all activity (new tickets, closed '
|
||||||
'tickets, updates, reassignments, etc) for this queue'),
|
'tickets, updates, reassignments, etc) for this queue. Separate '
|
||||||
|
'multiple addresses with a comma.'),
|
||||||
)
|
)
|
||||||
|
|
||||||
email_box_type = models.CharField(
|
email_box_type = models.CharField(
|
||||||
|
Loading…
x
Reference in New Issue
Block a user