When I construct the URL for a link with parameters, parameter value in link address shows up as HTML form instead of value.
This is how I am generating the link in my template:
<a class="btn btn-success btn-block" href="{% url 'facility_page' facility_id=facility.id %} " role="button">Edit</a>
This is how link address shows up:
http://127.0.0.1:8000/facility/(%3FP%3Cinput%20type=%22hidden%22%20name=%22facility-0-id%22%20value=%221%22%20id=%22id_facility-0-id%22%3E%5B0-9%5D+)/
I was expecting the link to look like this:
http://127.0.0.1:8000/facility/1
What am I doing wrong here?
urls.py
# path('facility/<int:facility_id>/', facility, name='facility_page'),
path('facility/<int>/', facility, name='facility_page'),