{# Console toolbar #} {% include 'console/toolbar.twig' with { 'parent_div_classes': 'collapsed', 'content_array': [ {0: 'switch_button console_switch', 1: 'Console'|trans, 'image': image}, ['button clear', 'Clear'|trans], ['button history', 'History'|trans], ['button options', 'Options'|trans], has_bookmark_feature ? ['button bookmarks', 'Bookmarks'|trans] : null, ['button debug hide', 'Debug SQL'|trans] ] } only %} {# Console messages #}
{% trans 'Press Ctrl+Enter to execute query' %} {% trans 'Press Enter to execute query' %}
{% if sql_history is not empty %} {% for record in sql_history|reverse %} {% endfor %} {% endif %}
{# Drak the console with other cards over it #}
{# Debug SQL card #}
{% include 'console/toolbar.twig' with { 'parent_div_classes': '', 'content_array': [ ['button order order_asc', 'ascending'|trans], ['button order order_desc', 'descending'|trans], ['text', 'Order:'|trans], ['switch_button', 'Debug SQL'|trans], ['button order_by sort_count', 'Count'|trans], ['button order_by sort_exec', 'Execution order'|trans], ['button order_by sort_time', 'Time taken'|trans], ['text', 'Order by:'|trans], ['button group_queries', 'Group queries'|trans], ['button ungroup_queries', 'Ungroup queries'|trans] ] } only %}
{% include 'console/query_action.twig' with { 'parent_div_classes': 'debug_query action_content', 'content_array': [ ['action collapse', 'Collapse'|trans], ['action expand', 'Expand'|trans], ['action dbg_show_trace', 'Show trace'|trans], ['action dbg_hide_trace', 'Hide trace'|trans], ['text count hide', 'Count'|trans], ['text time', 'Time taken'|trans] ] } only %}
{% if has_bookmark_feature %}
{% include 'console/toolbar.twig' with { 'parent_div_classes': '', 'content_array': [ ['switch_button', 'Bookmarks'|trans], ['button refresh', 'Refresh'|trans], ['button add', 'Add'|trans] ] } only %}
{{ bookmark_content|raw }}
{% include 'console/toolbar.twig' with { 'parent_div_classes': '', 'content_array': [ ['switch_button', 'Add bookmark'|trans] ] } only %}
{% endif %} {# Options card #}
{% include 'console/toolbar.twig' with { 'parent_div_classes': '', 'content_array': [ ['switch_button', 'Options'|trans], ['button default', 'Set default'|trans] ] } only %}





{# Templates for console message actions #} {% include 'console/query_action.twig' with { 'parent_div_classes': 'query_actions', 'content_array': [ ['action collapse', 'Collapse'|trans], ['action expand', 'Expand'|trans], ['action requery', 'Requery'|trans], ['action edit', 'Edit'|trans], ['action explain', 'Explain'|trans], ['action profiling', 'Profiling'|trans], has_bookmark_feature ? ['action bookmark', 'Bookmark'|trans] : null, ['text failed', 'Query failed'|trans], {0: 'text targetdb', 1: 'Database'|trans, 'extraSpan': ''}, {0: 'text query_time', 1: 'Queried time'|trans, 'extraSpan': ''} ] } only %}