Account for DB aliases when recording transaction state
Account for DB aliases when recording transaction state

The logic in SQLPanel.generate_stats() did not properly account for the
DB alias when marking transactions as ended.  It would always mark the
previous query as ending the transaction even if the previous query was
from a different DB alias.

Update the code to track the last query by alias so that the correct
query can be marked as ending the transaction.

jazzband/django-debug-toolbar,spookylukey/django-debug-toolbar,tim-schilling/django-debug-toolbar,tim-schilling/django-debug-toolbar,tim-schilling/django-debug-toolbar,spookylukey/django-debug-toolbar,jazzband/django-debug-toolbar,jazzband/django-debug-toolbar,spookylukey/django-debug-toolbar