Skip to content

Add "show" button on edit post #516

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

Merged
merged 1 commit into from
Mar 24, 2017
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
4 changes: 4 additions & 0 deletions app/Resources/translations/messages.en.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,10 @@
<source>action.show</source>
<target>Show</target>
</trans-unit>
<trans-unit id="action.show_post">
<source>action.show_post</source>
<target>Show post</target>
</trans-unit>
<trans-unit id="action.show_code">
<source>action.show_code</source>
<target>Show code</target>
Expand Down
6 changes: 6 additions & 0 deletions app/Resources/views/admin/blog/edit.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,12 @@
{% endblock %}

{% block sidebar %}
<div class="section">
<a href="{{ path('admin_post_show', { id: post.id }) }}" class="btn btn-lg btn-block btn-success">
<i class="fa fa-eye" aria-hidden="true"></i> {{ 'action.show_post'|trans }}
</a>
</div>

<div class="section actions">
{{ include('admin/blog/_delete_form.html.twig', { post: post }, with_context = false) }}
</div>
Expand Down