diff options
author | Kevin Decherf <kevin@kdecherf.com> | 2020-03-15 13:54:44 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-03-15 13:54:44 +0100 |
commit | f38b8f0d8671217efb818c964329ff0c529dfef8 (patch) | |
tree | 8bff1cbf3a716772cc52aa0146dcebd2e9d187aa /src/Wallabag/CoreBundle/Resources/views/themes/material/Entry | |
parent | ba820b12b691ecbbcc4a4c31ecb4dbeb084d27dd (diff) | |
parent | 80609790ca7e94a31bf3c770ad02d310c1022890 (diff) | |
download | wallabag-f38b8f0d8671217efb818c964329ff0c529dfef8.tar.gz wallabag-f38b8f0d8671217efb818c964329ff0c529dfef8.tar.zst wallabag-f38b8f0d8671217efb818c964329ff0c529dfef8.zip |
Merge pull request #4278 from wallabag/fix/4240
Fix entries export from search view
Diffstat (limited to 'src/Wallabag/CoreBundle/Resources/views/themes/material/Entry')
-rw-r--r-- | src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/entries.html.twig | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/entries.html.twig b/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/entries.html.twig index 3906e1e0..0c21dc5d 100644 --- a/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/entries.html.twig +++ b/src/Wallabag/CoreBundle/Resources/views/themes/material/Entry/entries.html.twig | |||
@@ -63,15 +63,20 @@ | |||
63 | {% if tag is defined %} | 63 | {% if tag is defined %} |
64 | {% set currentTag = tag.slug %} | 64 | {% set currentTag = tag.slug %} |
65 | {% endif %} | 65 | {% endif %} |
66 | {% set exportSearchTerm = null %} | ||
67 | {% if searchTerm is defined %} | ||
68 | {% set exportSearchTerm = searchTerm %} | ||
69 | {% endif %} | ||
70 | {% set previousRoute = app.request.attributes.get('currentRoute') %} | ||
66 | <h4 class="center">{{ 'entry.list.export_title'|trans }}</h4> | 71 | <h4 class="center">{{ 'entry.list.export_title'|trans }}</h4> |
67 | <ul> | 72 | <ul> |
68 | {% if craue_setting('export_epub') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', { 'category': currentRoute, 'format': 'epub', 'tag' : currentTag }) }}">EPUB</a></li>{% endif %} | 73 | {% if craue_setting('export_epub') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', { 'category': currentRoute, 'format': 'epub', 'tag' : currentTag, 'search_entry[term]' : exportSearchTerm, 'currentRoute' : previousRoute }) }}">EPUB</a></li>{% endif %} |
69 | {% if craue_setting('export_mobi') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', { 'category': currentRoute, 'format': 'mobi', 'tag' : currentTag }) }}">MOBI</a></li>{% endif %} | 74 | {% if craue_setting('export_mobi') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', { 'category': currentRoute, 'format': 'mobi', 'tag' : currentTag, 'search_entry[term]' : exportSearchTerm, 'currentRoute' : previousRoute }) }}">MOBI</a></li>{% endif %} |
70 | {% if craue_setting('export_pdf') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', { 'category': currentRoute, 'format': 'pdf', 'tag' : currentTag }) }}">PDF</a></li>{% endif %} | 75 | {% if craue_setting('export_pdf') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', { 'category': currentRoute, 'format': 'pdf', 'tag' : currentTag, 'search_entry[term]' : exportSearchTerm, 'currentRoute' : previousRoute }) }}">PDF</a></li>{% endif %} |
71 | {% if craue_setting('export_json') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', { 'category': currentRoute, 'format': 'json', 'tag' : currentTag }) }}">JSON</a></li>{% endif %} | 76 | {% if craue_setting('export_json') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', { 'category': currentRoute, 'format': 'json', 'tag' : currentTag, 'search_entry[term]' : exportSearchTerm, 'currentRoute' : previousRoute }) }}">JSON</a></li>{% endif %} |
72 | {% if craue_setting('export_csv') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', { 'category': currentRoute, 'format': 'csv', 'tag' : currentTag }) }}">CSV</a></li>{% endif %} | 77 | {% if craue_setting('export_csv') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', { 'category': currentRoute, 'format': 'csv', 'tag' : currentTag, 'search_entry[term]' : exportSearchTerm, 'currentRoute' : previousRoute }) }}">CSV</a></li>{% endif %} |
73 | {% if craue_setting('export_txt') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', { 'category': currentRoute, 'format': 'txt', 'tag' : currentTag }) }}">TXT</a></li>{% endif %} | 78 | {% if craue_setting('export_txt') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', { 'category': currentRoute, 'format': 'txt', 'tag' : currentTag, 'search_entry[term]' : exportSearchTerm, 'currentRoute' : previousRoute }) }}">TXT</a></li>{% endif %} |
74 | {% if craue_setting('export_xml') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', { 'category': currentRoute, 'format': 'xml', 'tag' : currentTag }) }}">XML</a></li>{% endif %} | 79 | {% if craue_setting('export_xml') %}<li class="bold"><a class="waves-effect" href="{{ path('export_entries', { 'category': currentRoute, 'format': 'xml', 'tag' : currentTag, 'search_entry[term]' : exportSearchTerm, 'currentRoute' : previousRoute }) }}">XML</a></li>{% endif %} |
75 | </ul> | 80 | </ul> |
76 | </div> | 81 | </div> |
77 | 82 | ||