gridBuilder.newFormHeading(getString("system.admin.group.title.alertMessage"));
{
final FieldsetPanel fs = gridBuilder.newFieldset(getString("system.admin.group.title.alertMessage"));
alertMessage = WicketApplication.getAlertMessage();
fs.add(new MaxLengthTextArea(TextAreaPanel.WICKET_ID, new PropertyModel<String>(this, "alertMessage"), 1000)).setAutogrow();
}
{
final FieldsetPanel fs = gridBuilder.newFieldset("").suppressLabelForWarning();
fs.add(new MyButtonPanel(fs.newChildId(), "setAlertMessage") {
@Override
public void onSubmit()
{
parentPage.setAlertMessage();
}
}.getButtonPanel());
fs.add(new MyButtonPanel(fs.newChildId(), "clearAlertMessage") {
@Override
public void onSubmit()
{
parentPage.clearAlertMessage();
}
/**
* @see org.projectforge.web.admin.AdminForm.MyButtonPanel#isVisible()
*/
@Override
public boolean isVisible()
{
return StringUtils.isNotBlank(alertMessage);
}
}.getButtonPanel());
}
{
final FieldsetPanel fs = gridBuilder.newFieldset(getString("system.admin.alertMessage.copyAndPaste.title")).suppressLabelForWarning();
fs.add(new DivTextPanel(fs.newChildId(), PFUserContext.getLocalizedMessage("system.admin.alertMessage.copyAndPaste.text",
AppVersion.NUMBER)));
}
gridBuilder.newSplitPanel(GridSize.COL50);
{
final FieldsetPanel fs = gridBuilder.newFieldset(getString("system.admin.reindex.newestEntries"),
getString("system.admin.reindex.newestEntries.subtitle"));
fs.add(new MinMaxNumberField<Integer>(InputPanel.WICKET_ID, new PropertyModel<Integer>(this, "reindexNewestNEntries"), 0,
Integer.MAX_VALUE));
fs.addHelpIcon(getString("system.admin.reindex.newestEntries.tooltip"));
}
{
final FieldsetPanel fs = gridBuilder.newFieldset(getString("system.admin.reindex.fromDate"));
final DatePanel datePanel = new DatePanel(fs.newChildId(), new PropertyModel<Date>(this, "reindexFromDate"));
fs.add(datePanel);
fs.addHelpIcon(new Model<String>() {
@Override
public String getObject()
{
return getString("system.admin.reindex.fromDate.tooltip")
+ (reindexFromDate != null ? " (" + DateHelper.formatAsUTC(reindexFromDate) + ")" : "");
}
});
fs.add(new MyButtonPanel(fs.newChildId(), "reindex") {
@Override
public void onSubmit()
{
parentPage.reindex();
}
}.getButtonPanel());
}
gridBuilder.newGridPanel();
{
final FieldsetPanel fs = gridBuilder.newFieldset(getString("system.admin.group.title.misc.logEntries"));
final MaxLengthTextArea logEntries = new MaxLengthTextArea(TextAreaPanel.WICKET_ID, new PropertyModel<String>(this, "logEntries"),
10000);
logEntries.add(AttributeModifier.append("style", "width: 100%; height: 20em;"));
fs.add(logEntries);
fs.addHelpIcon(getString("system.admin.button.formatLogEntries.textarea.tooltip"));
}
{
final FieldsetPanel fs = gridBuilder.newFieldset("").suppressLabelForWarning();