J'ai le code quelque chose comme ça, alors comment puis-je écrire 6.x ou 7.x wicket 1.setRedirect (true) 6.x ou 7.x
catch (Exception e) {
log.error("**** Exception ***********");
setRedirect(true);
log.errorException(e);
showErrorMsg(getLocalizer().getString("request.process.page.error", this));
}
2.
if (admin != null && admin.getId().equalsIgnoreCase(aId) == false) {
log.error("UserId do not match");
setRedirect(true);
showErrorMsg(getLocalizer().getString("internal.user.gccverf.auth.failed", this));
}
J'ai méthode comme celle
private void showErrorMsg(String errorMsg) {
setResponsePage(new ErrorPage(this.getPage(), getLocalizer().getString("label.applicaiton.error.page", this), errorMsg));
}
Vous voulez dire comme ça? Catch (Exception e) { \t log.error ("**** Exception ***********"); \t \t \t \t setResponsePage (getPage(). GetPageClass(), getPage(). GetPageParameters()); log.errorException (e); ShowErrorMsg (getLocalizer(). GetString ("request.process.page.error", this)); \t \t \t \t \t \t \t \t} –
martin voulait dire 'getSession() erreur (erreur de votre msg).' Vous devez essayer comme ça – soorapadman
Vous voulez dire catch (Exception e) { \t \t \t \t log.error (» **** Exception *********** "); \t \t \t \t setResponsePage (.. GetPage() getPageClass(), (getPage) getPageParameters()); log.errorException (e); \t \t \t \t getSession(). Error ("request.process.page.error"); \t \t \t \t \t \t \t} –