diff options
Diffstat (limited to 'bitbake')
-rw-r--r-- | bitbake/lib/toaster/toastergui/views.py | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/bitbake/lib/toaster/toastergui/views.py b/bitbake/lib/toaster/toastergui/views.py index 4f31ddb4bf..8f6e201ec2 100644 --- a/bitbake/lib/toaster/toastergui/views.py +++ b/bitbake/lib/toaster/toastergui/views.py | |||
@@ -192,7 +192,8 @@ def _get_queryset(model, queryset, filter_string, search_term, ordering_string): | |||
192 | else: | 192 | else: |
193 | queryset = queryset.order_by(column) | 193 | queryset = queryset.order_by(column) |
194 | 194 | ||
195 | return queryset | 195 | # insure only distinct records (e.g. from multiple search hits) are returned |
196 | return queryset.distinct() | ||
196 | 197 | ||
197 | # shows the "all builds" page | 198 | # shows the "all builds" page |
198 | def builds(request): | 199 | def builds(request): |
@@ -1060,10 +1061,8 @@ def configvars(request, build_id): | |||
1060 | return _redirect_parameters( 'configvars', request.GET, mandatory_parameters, build_id = build_id) | 1061 | return _redirect_parameters( 'configvars', request.GET, mandatory_parameters, build_id = build_id) |
1061 | 1062 | ||
1062 | queryset = Variable.objects.filter(build=build_id).exclude(variable_name__istartswith='B_').exclude(variable_name__istartswith='do_') | 1063 | queryset = Variable.objects.filter(build=build_id).exclude(variable_name__istartswith='B_').exclude(variable_name__istartswith='do_') |
1063 | queryset_with_search = _get_queryset(Variable, queryset, None, search_term, ordering_string).distinct().exclude(variable_value='',vhistory__file_name__isnull=True) | 1064 | queryset_with_search = _get_queryset(Variable, queryset, None, search_term, ordering_string).exclude(variable_value='',vhistory__file_name__isnull=True) |
1064 | queryset = _get_queryset(Variable, queryset, filter_string, search_term, ordering_string) | 1065 | queryset = _get_queryset(Variable, queryset, filter_string, search_term, ordering_string) |
1065 | # remove duplicate records from multiple search hits in the VariableHistory table | ||
1066 | queryset = queryset.distinct() | ||
1067 | # remove records where the value is empty AND there are no history files | 1066 | # remove records where the value is empty AND there are no history files |
1068 | queryset = queryset.exclude(variable_value='',vhistory__file_name__isnull=True) | 1067 | queryset = queryset.exclude(variable_value='',vhistory__file_name__isnull=True) |
1069 | 1068 | ||