【发布时间】:2015-06-08 17:40:05
【问题描述】:
//TrainingDialog associated with save button
trainingDialog = new MessageDialog("trainingdialog", "Warning", "Message contents here",
DialogButtons.OK, DialogIcon.WARN) {
public void onClose(AjaxRequestTarget target, DialogButton button) {
if (button != null && button.match(LBL_OK)) {
target.prependJavaScript("return saveClick()");
saveButton.add(new AttributeModifier("onclick", "return saveClick()"));
target.add(saveButton);
//note: predefined button text are:
//LBL_OK, LBL_CANCEL, LBL_YES, LBL_NO, LBL_CLOSE, LBL_SUBMIT
}
}
};
add(trainingDialog);
现在在我显示对话框之前使用 trainingdialog.open(目标)
有没有办法更新对话框的内容?
【问题讨论】:
标签: java jakarta-ee wicket