def set_cached_choices(self,choices): if not self.cache_config['enabled']: return c = get_cache(self.cache_config['cache']) return c.set(self.cache_config['key']%self.field_path,choices)
def get_cached_choices(self): if not self.cache_config['enabled']: return None c = get_cache(self.cache_config['cache']) return c.get(self.cache_config['key']%self.field_path)