// FIXME resetting the caches breaks the context in the embedded component public void resetCaches() { // log.debug("Resetting caches"); // takeValueForKey(null,"_task"); // this will break in 5.0 :-) // takeValueForKey(null,"_entityName"); // Finalizing a context is a protected method, hence the utility. // ERD2WUtilities.finalizeContext((D2WContext)valueForKey("subContext")); // takeValueForKey(null,"_context"); // HACK HACK HACK ak: When you have several embedded list components in // a tab page // D2W gets very confused about the keys. It will assume that the // objects on the second tab somehow belong to the first // resetting the cache when setting a new page configuration prevents // this D2WContext subContext = (D2WContext) valueForKey("subContext"); ERD2WUtilities.resetContextCache(subContext); subContext.setDynamicPage((String) valueForBinding("_dynamicPage")); subContext.takeValueForKey(D2WModel.One, D2WModel.FrameKey); subContext.takeValueForKey(session(), D2WModel.SessionKey); }