def decorator(func): filter_method = helper.get_django_filter(django_builtin_filter, load) @wraps(func) def wrapper(*args, **kwargs): value = func(*args, **kwargs) return filter_method(value, *extra) return wrapper
def decorator(func): filter_method = helper.get_django_filter(django_builtin_filter, load) @wraps(func) def wrapper(*args, **kwargs): value = func(*args, **kwargs) return filter_method(value, *extra) return wrapper
def render(self, obj): value = super(CacheAdminField, self).render(obj) filter_method = helper.get_django_filter(self.filter, self.load) args = (self.extra) if self.extra else [] return filter_method(value, *args)
def render(self, obj): value = super(CacheAdminField, self).render(obj) filter_method = helper.get_django_filter(self.filter, self.load) args = (self.extra) if self.extra else [] return filter_method(value, *args)