1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223
|
<tr id="row_tbl_{{ curr }}"{{ table_is_view ? ' class="is_view"' }} data-filter-row="{{ current_table['TABLE_NAME']|upper }}">
<td class="center print_ignore">
<input type="checkbox"
name="selected_tbl[]"
class="{{ input_class }}"
value="{{ current_table['TABLE_NAME'] }}"
id="checkbox_tbl_{{ curr }}">
</td>
<th>
<a href="sql.php{{ tbl_url_query|raw }}&pos=0" title="{{ browse_table_label_title }}">
{{ browse_table_label_truename }}
</a>
{{ tracking_icon|raw }}
</th>
{% if server_slave_status %}
<td class="center">
{{ ignored ? get_image('s_cancel', 'Not replicated'|trans) }}
{{ do ? get_image('s_success', 'Replicated'|trans) }}
</td>
{% endif %}
{# Favorite table anchor #}
{% if num_favorite_tables > 0 %}
<td class="center print_ignore">
{# Check if current table is already in favorite list #}
{% set fav_params = {
'db': db,
'ajax_request': true,
'favorite_table': current_table['TABLE_NAME'],
((already_favorite ? 'remove' : 'add') ~ '_favorite'): true
} %}
{% include 'database/structure/favorite_anchor.twig' with {
'table_name_hash': table_name_hash,
'db_table_name_hash': db_table_name_hash,
'fav_params': fav_params,
'already_favorite': already_favorite,
'titles': titles
} only %}
</td>
{% endif %}
<td class="center print_ignore">
<a href="sql.php{{ tbl_url_query|raw }}&pos=0">
{{ browse_table_title|raw }}
</a>
</td>
<td class="center print_ignore">
<a href="tbl_structure.php{{ tbl_url_query|raw }}">
{{ titles['Structure']|raw }}
</a>
</td>
<td class="center print_ignore">
<a href="tbl_select.php{{ tbl_url_query|raw }}">
{{ search_table_title|raw }}
</a>
</td>
{% if not db_is_system_schema %}
<td class="insert_table center print_ignore">
<a href="tbl_change.php{{ tbl_url_query|raw }}">{{ titles['Insert']|raw }}</a>
</td>
{% if table_is_view %}
<td class="center print_ignore">
<a href="view_create.php{{- get_common({
'db': db,
'table': current_table['TABLE_NAME']
}) }}">{{ titles['Edit']|raw }}</a>
</td>
{% else %}
<td class="center print_ignore">
<a class="truncate_table_anchor ajax" href="sql.php" data-post="{{ tbl_url_query|raw }}&sql_query=
{{- empty_table_sql_query }}&message_to_show={{ empty_table_message_to_show }}">
{{ empty_table_title|raw }}
</a>
</td>
{% endif %}
<td class="center print_ignore">
<a class="ajax drop_table_anchor
{{- table_is_view or current_table['ENGINE'] == null ? ' view' }}"
href="sql.php" data-post="{{ tbl_url_query|raw }}&reload=1&purge=1&sql_query=
{{- drop_query|url_encode }}&message_to_show={{ drop_message|url_encode }}">
{{ titles['Drop']|raw }}
</a>
</td>
{% endif %}
{% if current_table['TABLE_ROWS'] is defined
and (current_table['ENGINE'] != null or table_is_view) %}
{# Get the row count #}
{% set row_count = format_number(current_table['TABLE_ROWS'], 0) %}
{# Content to be appended into 'tbl_rows' cell.
If row count is approximate, display it as an anchor to get real count. #}
<td class="value tbl_rows"
data-table="{{ current_table['TABLE_NAME'] }}">
{% if approx_rows %}
<a href="db_structure.php{{ get_common({
'ajax_request': true,
'db': db,
'table': current_table['TABLE_NAME'],
'real_row_count': 'true'
}) }}" class="ajax real_row_count">
<bdi>
~{{ row_count }}
</bdi>
</a>
{% else %}
{{ row_count }}
{% endif %}
{{ show_superscript|raw }}
</td>
{% if not (properties_num_columns > 1) %}
<td class="nowrap">
{% if current_table['ENGINE'] is not empty %}
{{ current_table['ENGINE'] }}
{% elseif table_is_view %}
{% trans 'View' %}
{% endif %}
</td>
{% if collation|length > 0 %}
<td class="nowrap">
{{ collation|raw }}
</td>
{% endif %}
{% endif %}
{% if is_show_stats %}
<td class="value tbl_size">
<a href="tbl_structure.php{{ tbl_url_query|raw }}#showusage">
<span>{{ formatted_size }}</span> <span class="unit">{{ unit }}</span>
</a>
</td>
<td class="value tbl_overhead">
{{ overhead|raw }}
</td>
{% endif %}
{% if not (show_charset > 1) %}
{% if charset|length > 0 %}
<td class="nowrap">
{{ charset|raw }}
</td>
{% endif %}
{% endif %}
{% if show_comment %}
{% set comment = current_table['Comment'] %}
<td>
{% if comment|length > limit_chars %}
<abbr title="{{ comment }}">
{{ comment|slice(0, limit_chars) }}
...
</abbr>
{% else %}
{{ comment }}
{% endif %}
</td>
{% endif %}
{% if show_creation %}
<td class="value tbl_creation">
{{ create_time }}
</td>
{% endif %}
{% if show_last_update %}
<td class="value tbl_last_update">
{{ update_time }}
</td>
{% endif %}
{% if show_last_check %}
<td class="value tbl_last_check">
{{ check_time }}
</td>
{% endif %}
{% elseif table_is_view %}
<td class="value tbl_rows">-</td>
<td class="nowrap">
{% trans 'View' %}
</td>
<td class="nowrap">---</td>
{% if is_show_stats %}
<td class="value tbl_size">-</td>
<td class="value tbl_overhead">-</td>
{% endif %}
{% if show_charset %}
<td></td>
{% endif %}
{% if show_comment %}
<td></td>
{% endif %}
{% if show_creation %}
<td class="value tbl_creation">-</td>
{% endif %}
{% if show_last_update %}
<td class="value tbl_last_update">-</td>
{% endif %}
{% if show_last_check %}
<td class="value tbl_last_check">-</td>
{% endif %}
{% else %}
{% if db_is_system_schema %}
{% set action_colspan = 3 %}
{% else %}
{% set action_colspan = 6 %}
{% endif %}
{% if num_favorite_tables > 0 %}
{% set action_colspan = action_colspan + 1 %}
{% endif %}
{% set colspan_for_structure = action_colspan + 3 %}
<td colspan="{{ colspan_for_structure - db_is_system_schema ? 6 : 9 }}"
class="center">
{% trans 'in use' %}
</td>
{% endif %}
</tr>
|