mountPackage() will mount all *Page* classes in the same package as the page used for the mount but it doesn't do anything else, i.e. it doesn't handle components or models or ...
mountPage() mounts just a single page without any knowledge about other pages, panels, models ... On Wed, Apr 13, 2011 at 11:19 AM, Christian Grobmeier <grobme...@gmail.com>wrote: > > do you really need mountPackage() ? > > I guess you actually need #mountPage() > > I find mountPackage("/", HomePage.class); as the culprit > > if I use only mountPage it leads to the situation of some components not > found. > My structure is like following: > > /HomePage.class > /App.class > /pages/login/LoginPage.class > /pages/login/LoginForm.class > /pages/login/LoginEntities.class > /pages/login/LoginBusinessLogic.class > /pages/login/LoginPage.html > ... > > The docs told me I could mount a whole package. As subfolders are not > mounted, I thougth this would work. > > However, if I only use mountPage, the missing css error is gone. But > then I am puzzled about mountPackage > > It seems I should restructure my app... is there a recommended way? > > > > > > > On Wed, Apr 13, 2011 at 11:07 AM, Christian Grobmeier > > <grobme...@gmail.com>wrote: > > > >> > can you paste your MyApp#init() ? > >> > >> Sure: > >> > >> @Override > >> public void init() { > >> super.init(); > >> getComponentInstantiationListeners().add( > >> new SpringComponentInjector(this)); > >> mountPackage("/", HomePage.class); > >> mountPackage("/feedback", FeedbackPage.class); > >> mountPackage("/login", LoginPage.class); > >> mountPackage("/test", TestPage.class); > >> this.getMarkupSettings().setStripWicketTags(true); > >> loadProperties(); > >> initSecurity(); > >> } > >> > >> loadProperties load a property file from web-inf as the name suggests > >> initSecurity is setting an > getSecuritySettings().setauthorizationStrategy() > >> - guess the latter two methods have nothing to do with my problem > >> > >> Cheers > >> > >> --------------------------------------------------------------------- > >> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > >> For additional commands, e-mail: users-h...@wicket.apache.org > >> > >> > > > > > > -- > > Martin Grigorov > > jWeekend > > Training, Consulting, Development > > http://jWeekend.com <http://jweekend.com/> > > > > > > -- > http://www.grobmeier.de > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > > -- Martin Grigorov jWeekend Training, Consulting, Development http://jWeekend.com <http://jweekend.com/>