Export listening history to csv (#57)

Still need to convert timestamps to more CPU-readable format and figure
out what to do about reading headers for importing.
This commit is contained in:
2018-11-06 22:58:38 -05:00
parent 3d6dff359d
commit fa2c5f7008
6 changed files with 37 additions and 23 deletions

View File

@@ -1,6 +1,6 @@
<!DOCTYPE html>
{% load static %}
{% load render_table from django_tables2 %}
{% load render_table export_url from django_tables2 %}
<html lang="en">
<head>
<meta charset="UTF-8">
@@ -10,7 +10,7 @@
</head>
<body>
<h1>{{ user_id }}'s Listening History</h1>
<a class="btn btn-primary disabled" href="" role="button">Export CSV</a>
<a class="btn btn-primary " href="{% export_url 'csv' %}" role="button">Export CSV</a>
{% render_table user_history_table %}
</body>
</html>