{% extends 'UMRAMemberBundle::nav.html.twig' %}

{% block modulecontent -%}
    <div class="page-header">
        <h2>Household of {{ entity.firstname }} {{ entity.lastname }}</h2>
        <h4 class="text-muted">Postal Name: <small>{{ entity.postalname }}</small>
    </div>

    {% include 'UMRAMemberBundle:Household:detail.html.twig' %}

    <ul class="list-inline">
        {% if is_granted('ROLE_ADMIN') %}
        <li>
            <a class="btn btn-default" href="{{ path('UMRA_Household') }}">
                Back to the list
            </a>
        </li>
        {% else %}
        <li>
            <a class="btn btn-default" href="{{ path('UMRA_Person_Profile') }}">
                Back to my profile
            </a>
        </li>
        {% endif %}
        <li>
            <a class="btn btn-primary" href="{{ path('UMRA_Household_edit', { 'id': entity.id }) }}">
                Edit
            </a>
        </li>
        <li>{{ form(delete_form) }}</li>
    </ul>
{% endblock %}

{% extends 'UMRAMemberBundle::nav.html.twig' %}

{% block modulecontent -%}
    <div class="page-header">
        <h2>Household of {{ entity.firstname }} {{ entity.lastname }}</h2>
        <h4 class="text-muted">Postal Name: <small>{{ entity.postalname }}</small>
    </div>

    {% include 'UMRAMemberBundle:Household:detail.html.twig' %}

    <ul class="list-inline">
        {% if is_granted('ROLE_CAN_VIEW_OTHER_HOUSEHOLD') %}
        <li>
            <a class="btn btn-default" href="{{ path('UMRA_Household') }}">
                Back to the list
            </a>
        </li>
        {% else %}
        <li>
            <a class="btn btn-default" href="{{ path('UMRA_Person_Profile') }}">
                Back to my profile
            </a>
        </li>
        {% endif %}
        <li>
            <a class="btn btn-primary" href="{{ path('UMRA_Household_edit', { 'id': entity.id }) }}">
                Edit
            </a>
        </li>
        <li>{{ form(delete_form) }}</li>
    </ul>
{% endblock %}

Hide back to household list button for users without ROLE_CAN_VIEW_OTHER_HOUSEHOLD
Hide back to household list button for users without ROLE_CAN_VIEW_OTHER_HOUSEHOLD

Signed-off-by: Max Fierke <0706025b2bbcec1ed8d64822f4eccd96314938d0@maxfierke.com>