Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revive export box of statistics #3221

Merged
merged 2 commits into from
Nov 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,11 @@
{% if request.region.statistics_enabled and perms.cms.view_statistics %}
{% block content %}
<div class="row">
<div class="col-sm-12">
<h1 class="heading">
{% translate "Statistics" %}
</h1>
</div>
<div class="xl:flex gap-3 pt-2">
<div class="xl:w-3/4">
{% include "statistics/statistics_chart.html" with box_id="statistics_chart" %}
Expand Down
31 changes: 30 additions & 1 deletion integreat_cms/cms/templates/statistics/statistics_sidebar.html
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ <h3 class="heading font-bold text-black">
{% endif %}
</div>
</div>
<div class="rounded border border-solid border-blue-500 shadow-2xl bg-white">
<div class="rounded border border-solid border-blue-500 shadow-2xl bg-white mb-2">
<div class="rounded p-4 bg-water-500">
<h3 class="heading font-bold text-black">
<i icon-name="calendar" class="pb-1"></i> {% translate "Adjust time period" %}
Expand Down Expand Up @@ -50,3 +50,32 @@ <h3 class="heading font-bold text-black">
</button>
</form>
</div>
<div class="rounded border border-solid border-blue-500 shadow-2xl bg-white mb-2">
MizukiTemma marked this conversation as resolved.
Show resolved Hide resolved
<div class="rounded p-4 bg-water-500">
<h3 class="heading font-bold text-black">
<i icon-name="download" class="pb-1"></i> {% translate "Export" %}
</h3>
</div>
<div class="flex flex-col gap-4 p-4 pt-2">
<label for="export-format">
{% translate "Choose format" %}
</label>
<select id="export-format"
data-filename-prefix="{% translate "Statistics" %} {{ request.region.name }}"
data-language-column-title="{% translate "Language" %}">
<option value="" selected>
--- {% translate "please select" %} ---
</option>
<option value="image">
{% translate "Image/PNG" %}
</option>
<option value="csv">
{% translate "Table Document/CSV" %}
</option>
</select>
<button id="export-button" class="btn" disabled>
{% translate "Export" %}
</button>
<a id="export-download-link" class="hidden"></a>
</div>
</div>
39 changes: 23 additions & 16 deletions integreat_cms/locale/de/LC_MESSAGES/django.po
Original file line number Diff line number Diff line change
Expand Up @@ -1961,6 +1961,7 @@ msgstr "Alle Regionen"
#: cms/templates/feedback/region_feedback_list_archived.html
#: cms/templates/languagetreenodes/languagetreenode_list.html
#: cms/templates/pages/_page_xliff_import_diff.html
#: cms/templates/statistics/statistics_sidebar.html
#: cms/views/feedback/feedback_resource.py
msgid "Language"
msgstr "Sprache"
Expand Down Expand Up @@ -4460,6 +4461,8 @@ msgstr "Analyse"

#: cms/templates/_base.html cms/templates/regions/region_form.html
#: cms/templates/statistics/_statistics_widget.html
#: cms/templates/statistics/statistics_overview.html
#: cms/templates/statistics/statistics_sidebar.html
msgid "Statistics"
msgstr "Statistiken"

Expand Down Expand Up @@ -8403,6 +8406,26 @@ msgstr "Zeitraum anpassen"
msgid "Customize view"
msgstr "Ansicht anpassen"

#: cms/templates/statistics/statistics_sidebar.html
msgid "Export"
msgstr "Exportieren"

#: cms/templates/statistics/statistics_sidebar.html
msgid "Choose format"
msgstr "Format auswählen"

#: cms/templates/statistics/statistics_sidebar.html
msgid "please select"
msgstr "bitte auswählen"

#: cms/templates/statistics/statistics_sidebar.html
msgid "Image/PNG"
msgstr "Bild/PNG"

#: cms/templates/statistics/statistics_sidebar.html
msgid "Table Document/CSV"
msgstr "Tabellendokument/CSV"

#: cms/templates/translations/translations_management.html
msgid "Manage machine translations"
msgstr "Maschinelle Übersetzungen verwalten"
Expand Down Expand Up @@ -11015,27 +11038,11 @@ msgstr ""
"Diese Seite konnte nicht importiert werden, da sie zu einer anderen Region "
"gehört ({})."


#~ msgid "Individual languages can be hidden by clicking on the labels."
#~ msgstr ""
#~ "Einzelne Sprachen können durch Anklicken der Beschriftungen ausgeblendet "
#~ "werden."

#~ msgid "Export"
#~ msgstr "Exportieren"

#~ msgid "Choose format"
#~ msgstr "Format auswählen"

#~ msgid "please select"
#~ msgstr "bitte auswählen"

#~ msgid "Image/PNG"
#~ msgstr "Bild/PNG"

#~ msgid "Table Document/CSV"
#~ msgstr "Tabellendokument/CSV"

#~ msgid "Copy"
#~ msgstr "(Kopie)"

Expand Down
2 changes: 2 additions & 0 deletions integreat_cms/release_notes/current/unreleased/3131.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
en: Make access number box of statistics collapsible
de: Mache Zugriffsnummernfeld der Statistik zusammenklappbar
MizukiTemma marked this conversation as resolved.
Show resolved Hide resolved
Loading