]> git.immae.eu Git - github/wallabag/wallabag.git/blobdiff - src/Wallabag/CoreBundle/Resources/views/Entry/entry.html.twig
store domainName in database
[github/wallabag/wallabag.git] / src / Wallabag / CoreBundle / Resources / views / Entry / entry.html.twig
index f0c0050949bf6d39bd8f5f30fd724a06511a5da4..00480d1aa6d6fc6fe1e12527548919aefa909d07 100644 (file)
@@ -1,16 +1,12 @@
 {% extends "WallabagCoreBundle::layout.html.twig" %}
 
-{% block title %}{{ entry.title|raw }} ({{ entry.url | e | domainName }}){% endblock %}
-
-{% block menu %}
-    {% include "WallabagCoreBundle::_menu.html.twig" %}
-{% endblock %}
+{% block title %}{{ entry.title|raw }} ({{ entry.domainName }}){% endblock %}
 
 {% block content %}
     <div id="article_toolbar">
         <ul class="links">
             <li class="topPosF"><a href="#top" title="{% trans %}Back to top{% endtrans %}" class="tool top icon icon-arrow-up-thick"><span>{% trans %}Back to top{% endtrans %}</span></a></li>
-            <li><a href="{{ entry.url|e }}" target="_blank" title="{% trans %}original{% endtrans %} : {{ entry.title|e }}" class="tool link icon icon-link"><span>{{ entry.url | e | domainName }}</span></a></li>
+            <li><a href="{{ entry.url|e }}" target="_blank" title="{% trans %}original{% endtrans %} : {{ entry.title|e }}" class="tool link icon icon-link"><span>{{ entry.domainName }}</span></a></li>
             <li><a title="{% trans %}Mark as read{% endtrans %}" class="tool icon icon-check {% if entry.isArchived == 0 %}archive-off{% else %}archive{% endif %}" href="{{ path('archive_entry', { 'id': entry.id }) }}"><span>{% trans %}Toggle mark as read{% endtrans %}</span></a></li>
             <li><a title="{% trans %}Favorite{% endtrans %}" class="tool icon icon-star {% if entry.isStarred == 0 %}fav-off{% else %}fav{% endif %}" href="{{ path('star_entry', { 'id': entry.id }) }}"><span>{% trans %}Toggle favorite{% endtrans %}</span></a></li>
             <li><a title="{% trans %}Delete{% endtrans %}" class="tool delete icon icon-trash" href="{{ path('delete_entry', { 'id': entry.id }) }}"><span>{% trans %}Delete{% endtrans %}</span></a></li>
             {#  {% if flattr %}{% if flattr.status == flattrable %}<li><a href="http://flattr.com/submit/auto?url={{ entry.url }}" class="tool flattr icon icon-flattr" target="_blank" title="{% trans %}flattr{% endtrans %}"><span>{% trans %}flattr{% endtrans %}</span></a></li>{% elseif flattr.status == flattred %}<li><a href="{{ flattr.flattrItemURL }}" class="tool flattr icon icon-flattr" target="_blank" title="{% trans %}flattr{% endtrans %}><span>{% trans %}flattr{% endtrans %}</span> ({{ flattr.numFlattrs }})</a></li>{% endif %}{% endif %} #}
             {% if carrot %}<li><a href="https://secure.carrot.org/GiveAndGetBack.do?url={{ entry.url|url_encode }}&title={{ entry.title|url_encode }}" class="tool carrot icon-image icon-image--carrot" target="_blank" title="{% trans %}carrot{% endtrans %}"><span>Carrot</span></a></li>{% endif %}
             {% if show_printlink %}<li><a title="{% trans %}Print{% endtrans %}" class="tool icon icon-print" href="javascript: window.print();"><span>{% trans %}Print{% endtrans %}</span></a></li>{% endif %}
-            {% if export_epub %}<li><a href="?epub&amp;method=id&amp;value={{ entry.id|e }}" title="Generate ePub file">EPUB</a></li>{% endif %}
-            {% if export_mobi %}<li><a href="?mobi&amp;method=id&amp;value={{ entry.id|e }}" title="Generate Mobi file">MOBI</a></li>{% endif %}
-            {% if export_pdf %}<li><a href="?pdf&amp;method=id&amp;value={{ entry.id|e }}" title="Generate PDF file">PDF</a></li>{% endif %}
+            {% if export_epub %}<li><a href="?epub&amp;method=id&amp;value={{ entry.id }}" title="Generate ePub file">EPUB</a></li>{% endif %}
+            {% if export_mobi %}<li><a href="?mobi&amp;method=id&amp;value={{ entry.id }}" title="Generate Mobi file">MOBI</a></li>{% endif %}
+            {% if export_pdf %}<li><a href="?pdf&amp;method=id&amp;value={{ entry.id }}" title="Generate PDF file">PDF</a></li>{% endif %}
             <li><a href="mailto:hello@wallabag.org?subject=Wrong%20display%20in%20wallabag&amp;body={{ entry.url|url_encode }}" title="{% trans %}Does this article appear wrong?{% endtrans %}" class="tool bad-display icon icon-delete"><span>{% trans %}Does this article appear wrong?{% endtrans %}</span></a></li>
         </ul>
     </div>
     <div id="article">
         <header class="mbm">
-            <h1>{{ entry.title|raw }}</h1>
+            <h1>{{ entry.title|raw }} <a href="{{ path('edit', { 'id': entry.id }) }}" title="{% trans %}Edit tags{% endtrans %}">✎</a></h1>
         </header>
         <aside class="tags">
-            tags: {# {% for tag in tags %}<a href="./?view=tag&amp;id={{ tag.id }}">{{ tag.value }}</a> {% endfor %}<a href="./?view=edit-tags&amp;id={{ entry.id|e }}" title="{% trans %}Edit tags{% endtrans %}">✎</a> #}
+            tags: {% for tag in entry.tags %}<a href="./?view=tag&amp;id={{ tag.id }}">{{ tag.label }}</a> {% endfor %}<a href="./?view=edit-tags&amp;id={{ entry.id }}" title="{% trans %}Edit tags{% endtrans %}">✎</a>
         </aside>
         <article>
             {{ entry.content | raw }}
                 var docHeight = $(document).height();
                 var scrollPercent = (scrollTop) / (docHeight);
                 var scrollPercentRounded = Math.round(scrollPercent*100)/100;
-                savePercent({{ entry.id|e }}, scrollPercentRounded);
+                savePercent({{ entry.id }}, scrollPercentRounded);
             });
 
-            retrievePercent({{ entry.id|e }});
+            retrievePercent({{ entry.id }});
 
             $(window).resize(function(){
-                retrievePercent({{ entry.id|e }});
+                retrievePercent({{ entry.id }});
             });
         });
     </script>