Hi Mark,
You would pass the form in the context of the template in the view. You can pass pretty much anything to a template through the context.
def builddetails(request, id):
build = Build.objects.get(pk=id)
form = BuildForm(request.POST or None)
if form.is_valid():
form.save()
return render(request, 'app/builddetails.html', { 'build': build, ‘form’: form })
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
django-users...@googlegroups.com.
To post to this group, send email to
django...@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-users/733168e2-2559-4726-9067-dc2a23397bb7%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
NOT NULL constraint failed: app_build.requested_by_id
To post to this group, send email to djang...@googlegroups.com.