mgraf
(Michael)
1
Hi,
is there a way to invalidate a BrowserView?
I collect all my NewsItems in @@news and call in everywhere.
Now I want to recreate the view on ObjectModified (or IActionSucceededEvent)...
But a simple Event subscriber with
```global_cache.invalidate('package.path.to.view.NewsAggregated')````
does nothing
my Function
@ram.cache(lambda *args: time.time() // (60 * 3600))
def NewsAggregated(self, location):
portal_catalog = api.portal.get_tool(name='portal_catalog')
results = portal_catalog(
path={
'query': location
},
portal_type=['News Item'],
review_state='published',
sort_on='effective',
sort_order='reverse'
)
.... other stuff
return [Newsitems Dicts]
alert
(Alessandro Pisa)
2
For sure popping out the annotations will work:
I am not aware of a smarter method.
2 Likes
alecghica1
(Alexandru Ghica)
3
This comment saved the day, thx! 
1 Like