def ward_form_renderer(request):
    if request.is_ajax():
        ward_form = WardForm()
context = {'wardform': ward_form}
context.update(csrf(request))
render(request, 'wardform_template', c)
Джанго ajax запрос