hybris: Cockpit Framework – Update BrowserArea / ListView
by admin on Jan.17, 2017, under Programming
The following will update items you may have created using a wizard in your ProducktCockpit (or any other custom extension derived from the cockpit framework).
For the ProductCockpit the bean is called “ExtAppPerspective” and can be found in productcockpit-web-spring.xml. For any custom extensions it’s called “Perspective” and can be found in -web-spring.xml
BaseUICockpitPerspective productSelectorPerspective = Registry.getApplicationContext().getBean("<YourExtensionName>Perspective", BaseUICockpitPerspective.class); productSelectorPerspective.getBrowserArea().getFocusedBrowser().updateItems();
The browserArea will update seamlessly and its content will be up-to-date again.