diff --git a/tailbone/views/batch/core.py b/tailbone/views/batch/core.py index de95c068..0f493bc9 100644 --- a/tailbone/views/batch/core.py +++ b/tailbone/views/batch/core.py @@ -634,13 +634,19 @@ class BatchMasterView(MasterView): g.status_code.set(label="Status", renderer=StatusRenderer(self.model_row_class.STATUS)) + + hide_row_status_codes = [] + def get_row_data(self, batch): """ Generate the base data set for a rows grid. """ - return self.Session.query(self.model_row_class)\ - .filter(self.model_row_class.batch == batch)\ - .filter(self.model_row_class.removed == False) + query = self.Session.query(self.model_row_class)\ + .filter(self.model_row_class.batch == batch)\ + .filter(self.model_row_class.removed == False) + if self.hide_row_status_codes: + query = query.filter(~self.model_row_class.status_code.in_(self.hide_row_status_codes)) + return query def row_editable(self, row): """