diff --git a/apps/registration/tables.py b/apps/registration/tables.py index 274369fe6ec856526db92dad3322fc0d29d2fb28..9b124ffa59caf17a1b22262aaa493cd83ba7229b 100644 --- a/apps/registration/tables.py +++ b/apps/registration/tables.py @@ -4,6 +4,8 @@ import django_tables2 as tables from django.contrib.auth.models import User +from treasury.models import SogeCredit + class FutureUserTable(tables.Table): """ @@ -21,6 +23,7 @@ class FutureUserTable(tables.Table): fields = ('last_name', 'first_name', 'username', 'email', ) model = User row_attrs = { - 'class': 'table-row', + 'class': lambda record: 'table-row' + + (' bg-warning' if SogeCredit.objects.filter(user=record).exists() else ''), 'data-href': lambda record: record.pk }