Reuse the map_download view/url for the dashboard

Refs #1396
This commit is contained in:
David Larlet 2023-11-24 15:28:58 -05:00
parent 1b87df7a7f
commit b4464a7ca2
No known key found for this signature in database
GPG key ID: 3E2953A359E7E7BD
2 changed files with 2 additions and 2 deletions

View file

@ -27,7 +27,7 @@
<td> <td>
<a href="{{ map_inst.get_absolute_url }}?share">{% translate "Share" %}</a> <a href="{{ map_inst.get_absolute_url }}?share">{% translate "Share" %}</a>
<a href="{{ map_inst.get_absolute_url }}?edit">{% translate "Edit" %}</a> <a href="{{ map_inst.get_absolute_url }}?edit">{% translate "Edit" %}</a>
<a href="{{ map_inst.get_absolute_url }}?download">{% translate "Download" %}</a> <a href="{% url 'map_download' map_inst.pk %}">{% translate "Download" %}</a>
</td> </td>
</tr> </tr>
{% endfor %} {% endfor %}

View file

@ -280,7 +280,7 @@ def test_user_dashboard_display_user_maps(client, map):
assert map.name in body assert map.name in body
assert f"{map.get_absolute_url()}?edit" in body assert f"{map.get_absolute_url()}?edit" in body
assert f"{map.get_absolute_url()}?share" in body assert f"{map.get_absolute_url()}?share" in body
assert f"{map.get_absolute_url()}?download" in body assert f"/map/{map.pk}/download" in body
assert "Everyone (public)" in body assert "Everyone (public)" in body
assert "Owner only" in body assert "Owner only" in body