booking.pdf = PDFTemplater.makePDF(booking)
for collaborator in users_field: # list of Users (not UserProfile)
- booking.collaborators.add(collaborator.user)
+ booking.collaborators.add(collaborator)
booking.save()
from workflow.views import login
from booking.forms import QuickBookingForm
from booking.quick_deployer import create_from_form, drop_filter
+import traceback
def quick_create_clear_fields(request):
"Check Account->My Bookings for the status of your new booking")
return redirect(reverse('booking:booking_detail', kwargs={'booking_id': booking.id}))
except Exception as e:
+ print("Error occurred while handling quick deployment:")
+ traceback.print_exc()
+ print(str(e))
messages.error(request, "Whoops, an error occurred: " + str(e))
context.update(drop_filter(request.user))
return render(request, 'booking/quick_deploy.html', context)