From 37b9a81344b2f391be9f6ab10b4bf6e33f642011 Mon Sep 17 00:00:00 2001 From: Lance Edgar Date: Wed, 7 Nov 2018 16:47:41 -0600 Subject: [PATCH] Add `Grid.hide_columns()` convenience method --- tailbone/grids/core.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tailbone/grids/core.py b/tailbone/grids/core.py index 59149d55..31c36907 100644 --- a/tailbone/grids/core.py +++ b/tailbone/grids/core.py @@ -130,6 +130,10 @@ class Grid(object): if key in self.columns: self.columns.remove(key) + def hide_columns(self, *keys): + for key in keys: + self.hide_column(key) + def append(self, field): self.columns.append(field)