ok, think I've figured it out. Try again.
On 22 February 2013 00:22, Christian Steinebach < [email protected]> wrote: > Hi Dan! > > First time I called warnUser(), nothing happened :-( > yup, the JQuery wasn't loaded, I think. > How should the the methods be used? I called warnUser() in an action > method. > > public TransportDemand sendEvent(@Named("Event") Event event, > @Named("Leg") InstantiatedServedRoute sr, > @Named("Comment") String comment) { > processEvent(event, sr, comment); > warnUser(event + ": " + comment); > return this; > } > > Would that be ok? > yup. > > What are the two buttons supposed to do, 'Normal ok' and 'Ajax ok'? > removed - was left by accident. Also.. try throwing a RuntimeException from a method, and check get directed to the new error page. Cheers Dan > > Regards > Christian > > > ________________________________________ > From: Dan Haywood [[email protected]] > Sent: Thursday, February 21, 2013 8:40 PM > To: users > Subject: Wicket viewer now handles notifications, warnings and exceptions > > fyi, just checked in a couple of enhancements for the Wicket viewer > (ISIS-349, ISIS-350): > > * getContainer().informUser(...) will raise a growl-like notification; > this hides automatically after a while [blue accent colour] > * getContainer().warnUser(...) raises a similar notification, but which > must be acknowledged [orange] > * getContainer().raiseError(...) also raises a notification, but which must > be acknowledged [red] > > As an alternative to raiseError(), you can also just throw new > ApplicationException(...) - defined in the applib. The two are equivalent, > use whichever you prefer. > > In addition, if any unhandled runtime exceptions occur, these are now > caught and rendered more pleasantly than before. > > Check it out, let me know if you hit issues > > Dan >
