Reputation: 1153
I'm trying to display list of clinics but I keep getting the following error:
Exception Type: TemplateSyntaxError at /clinics/
Exception Value: Invalid block tag: 'c.name', expected 'empty' or 'endfor'
Here is the clinicList.html
{% for c in clinics %}
{% c.name %}
{% endfor %}
here is the views
def clinicList(request):
d = getVariables(request,dictionary={'page_name':""})
d.update({'clinics': Clinic.objects.all()})
return render(request, 'm1/clinicList.html', d)
here is url.py
url(r'^clinics/$', views.clinicList, name='clinicList'),
Upvotes: 2
Views: 7481