mirror of
https://github.com/django-helpdesk/django-helpdesk.git
synced 2025-08-13 01:37:32 +02:00
Allow a file to be attached to the ticket when the ticket is opened. These files are attached to outgoing emails. Also, updated forms to loop over form.fields rather than explicitly naming each field. Fixes issue #15.
This commit is contained in:
@ -402,7 +402,7 @@ ticket_list = staff_member_required(ticket_list)
|
||||
|
||||
def create_ticket(request):
|
||||
if request.method == 'POST':
|
||||
form = TicketForm(request.POST)
|
||||
form = TicketForm(request.POST, request.FILES)
|
||||
form.fields['queue'].choices = [('', '--------')] + [[q.id, q.title] for q in Queue.objects.all()]
|
||||
form.fields['assigned_to'].choices = [('', '--------')] + [[u.id, u.username] for u in User.objects.filter(is_active=True)]
|
||||
if form.is_valid():
|
||||
|
Reference in New Issue
Block a user