From 83f3c20fa76ff383d069ca866cb2eee92fe0c9c8 Mon Sep 17 00:00:00 2001 From: Cédric Bonhomme Date: Mon, 29 May 2017 23:15:17 +0200 Subject: It is now possible to filter bookmarks by tags. --- src/web/controllers/abstract.py | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/web/controllers') diff --git a/src/web/controllers/abstract.py b/src/web/controllers/abstract.py index 8563d5f2..47cc365f 100644 --- a/src/web/controllers/abstract.py +++ b/src/web/controllers/abstract.py @@ -50,6 +50,8 @@ class AbstractController: db_filters.add(getattr(self._db_cls, key[:-4]) != value) elif key.endswith('__in'): db_filters.add(getattr(self._db_cls, key[:-4]).in_(value)) + elif key.endswith('__contains'): + db_filters.add(getattr(self._db_cls, key[:-10]).contains(value)) elif key.endswith('__like'): db_filters.add(getattr(self._db_cls, key[:-6]).like(value)) elif key.endswith('__ilike'): -- cgit