{% extends 'D2CommentBundle::base_admin.html.twig' %} {% block head_script_extra %} {% endblock head_script_extra %} {% block head_style_extra %} {% endblock head_style_extra %} {% block page_header %}
{% for k, v in app.request.query %} {% if k|lower not in ['search', 'page', 'status', 'approved', 'customers', 'type'] %} {% endif %} {% endfor %}
Displaying {{ (comment_list.getCurrentPageNumber()-1) * comment_list.getItemNumberPerPage() + 1 }} to {{ ((comment_list.getCurrentPageNumber()-1) * comment_list.getItemNumberPerPage()) + (comment_list.getItems()|length) }} of {{ comment_list.getTotalItemCount() }} Comment records
{% endblock page_header %} {% block content %}
{% for entity in comment_list %} {# {% if entity.parentComment is not null %} {% set entity = entity.parentComment %} {% endif %} #} {% set replies = d2_comment_get_all_replies(entity.id) %} {% if replies|length > 0 %} {% for reply in replies %} {% endfor %} {% endif %} {% endfor %}
Type {{ knp_pagination_sortable(comment_list, 'Status', 'cs.enabled') }} {{ knp_pagination_sortable(comment_list, 'Contributor', 'c.customer') }} {{ knp_pagination_sortable(comment_list, 'Comment', 'cs.comment') }} {{ knp_pagination_sortable(comment_list, 'Date', 'cs.date') }}
COMMENT {{ entity.enabled ? 'Enabled' : 'Disabled' }} {% if entity.getCustomer is not null %}{{ entity.getCustomer.getFirstname|trim }} {{ entity.getCustomer.getLastname|trim }}{% endif %} {{ entity.comment|trim }} {{ entity.date|date("Y/m/d") }} {% if is_granted('ROLE_ADMIN_CASE_STUDY_MANAGE') %}
{% endif %}
REPLY {{ reply.enabled ? 'Enabled' : 'Disabled' }} {% if reply.getCustomer is not null %}{{ reply.getCustomer.getFirstname|trim }} {{ reply.getCustomer.getLastname|trim }}{% endif %} {{ reply.comment|trim }} {{ reply.date|date("Y/m/d") }} {% if is_granted('ROLE_ADMIN_CASE_STUDY_MANAGE') %} {% if entity.enabled %}
{% endif %} {% endif %}
{% endblock content %}