From: Michael Wood Date: Tue, 29 Sep 2015 04:45:15 +0000 (-0700) Subject: toaster: widgets ToasterTable Add more info to search field exception X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=8152db1e35b9a3f35a25f801008f6fc61a6b11c4;p=thirdparty%2Fopenembedded%2Fopenembedded-core-contrib.git toaster: widgets ToasterTable Add more info to search field exception If we get a search fields exception then also print out the model name Signed-off-by: Michael Wood Signed-off-by: brian avery Signed-off-by: Richard Purdie --- diff --git a/lib/toaster/toastergui/widgets.py b/lib/toaster/toastergui/widgets.py index 7f9637060d6..aaa59c083ed 100644 --- a/lib/toaster/toastergui/widgets.py +++ b/lib/toaster/toastergui/widgets.py @@ -229,7 +229,8 @@ class ToasterTable(TemplateView): """Creates a query based on the model's search_allowed_fields""" if not hasattr(self.queryset.model, 'search_allowed_fields'): - raise Exception("Err Search fields aren't defined in the model") + raise Exception("Search fields aren't defined in the model %s" + % self.queryset.model) search_queries = [] for st in search_term.split(" "):