diff options
| author | David Cramer | 2011-03-24 17:34:55 -0700 | 
|---|---|---|
| committer | David Cramer | 2011-03-24 17:34:55 -0700 | 
| commit | 79ddcefb629612da3fb05ccbb8b602d1f026b1f9 (patch) | |
| tree | 45aef5f80eb901e1aaa5d348925b0951c67b3ef2 /debug_toolbar/templates | |
| parent | 4bb644ad825ed9009176c7e78967b6ba07d7a681 (diff) | |
| download | django-debug-toolbar-79ddcefb629612da3fb05ccbb8b602d1f026b1f9.tar.bz2 | |
basic color code grouping of db aliases
Diffstat (limited to 'debug_toolbar/templates')
| -rw-r--r-- | debug_toolbar/templates/debug_toolbar/panels/sql.html | 7 | 
1 files changed, 5 insertions, 2 deletions
diff --git a/debug_toolbar/templates/debug_toolbar/panels/sql.html b/debug_toolbar/templates/debug_toolbar/panels/sql.html index cc9d6d0..6719ed6 100644 --- a/debug_toolbar/templates/debug_toolbar/panels/sql.html +++ b/debug_toolbar/templates/debug_toolbar/panels/sql.html @@ -3,8 +3,8 @@  	<ul class="stats">  		{% for alias, info in databases %}  			<li> -				<strong>{{ alias }}</strong> -				<span>{{ info.time_spent|floatformat:"2" }} ms ({% blocktrans count info.queries as num %}{{ num }} query{% plural %}{{ num }} queries{% endblocktrans %})</span> +				<strong class="label"><span style="background-color: rgb({{ info.rgb_color|join:", " }})" class="color"> </span> {{ alias }}</strong> +				<span class="info">{{ info.time_spent|floatformat:"2" }} ms ({% blocktrans count info.queries as num %}{{ num }} query{% plural %}{{ num }} queries{% endblocktrans %})</span>  			</li>  		{% endfor %}  	</ul> @@ -13,6 +13,7 @@  <table>  	<thead>  		<tr> +			<th class="color"> </th>  			<th class="query" colspan="2">{% trans 'Query' %}</th>  			<th class="timeline">{% trans 'Timeline' %}</th>  			<th class="time">{% trans 'Time (ms)' %}</th> @@ -22,6 +23,7 @@  	<tbody>  		{% for query in queries %}  			<tr class="djDebugHoverable {% cycle 'djDebugOdd' 'djDebugEven' %}{% if query.is_slow %} djDebugRowWarning{% endif %}" id="sqlMain_{{ forloop.counter }}"> +				<td class="color"><span style="background-color: rgb({{ query.rgb_color|join:", " }});"> </span></td>  				<td class="toggle">  					<a class="djSQLToggleDetails" data-queryid="{{ forloop.counter }}" href="javascript:void(0)">+</a>  				</td> @@ -49,6 +51,7 @@  				</td>  			</tr>  			<tr class="djDebugHoverable {% cycle 'djDebugOdd' 'djDebugEven' %}{% if query.is_slow %} djDebugRowWarning{% endif %}" id="sqlDetails_{{ forloop.counter }}"> +				<td class="color"><span style="background-color: rgb({{ query.rgb_color|join:", " }});"> </span></td>  				<td></td>  				<td colspan="4">  					<div class="djSQLDetailsDiv" style="display:none;">  | 
