protected BSFeedbackPanel newFeedbackPanel(String id, BSModalBorder fence, IFeedbackMessageFilter messageFilter) { return new BSFeedbackPanel(id, fence, messageFilter); }
public boolean anyMessage() { return feedbackGeral.anyMessage(); }
@Override protected void onConfigure() { super.onConfigure(); setVisible(anyMessage()); } }
@Override protected void onInitialize() { super.onInitialize(); setOutputMarkupId(true); setOutputMarkupPlaceholderTag(true); }
protected IFeedbackMessageFilter newIFeedbackMessageFilter() { return new NotContainedFeedbackMessageFilter(getBodyContainer()); }
@Override protected Component newMessageDisplayComponent(String id, FeedbackMessage message) { Component component = super.newMessageDisplayComponent(id, message); if (component instanceof Label) { final Label label = (Label) component; if (message instanceof SFeedbackMessage) { final SFeedbackMessage bfm = (SFeedbackMessage) message; final SInstance instance = bfm.getInstanceModel().getObject(); final SInstance parentContext = WicketFormUtils.resolveInstance(getFence()).orElse(null); final String labelPath = StringUtils.defaultString( WicketFormUtils.generateTitlePath(getFence(), parentContext, message.getReporter(), instance), SFormUtil.generatePath(instance, it -> it == parentContext)); label.setDefaultModelObject(labelPath + " : " + bfm.getMessage()); } } return component; } }
@Override protected void onConfigure() { super.onConfigure(); setVisible(anyMessage()); } }
@Override protected void onInitialize() { super.onInitialize(); setOutputMarkupId(true); setOutputMarkupPlaceholderTag(true); }
protected BSFeedbackPanel newFeedbackPanel(String id, BSModalBorder fence, IFeedbackMessageFilter messageFilter) { return new BSFeedbackPanel(id, fence, messageFilter); }
public boolean anyMessage() { return feedbackGeral.anyMessage(); }
protected IFeedbackMessageFilter newIFeedbackMessageFilter() { return new NotContainedFeedbackMessageFilter(getBodyContainer()); }
@Override protected Component newMessageDisplayComponent(String id, FeedbackMessage message) { Component component = super.newMessageDisplayComponent(id, message); if (component instanceof Label) { final Label label = (Label) component; if (message instanceof SFeedbackMessage) { final SFeedbackMessage bfm = (SFeedbackMessage) message; final SInstance instance = bfm.getInstanceModel().getObject(); final SInstance parentContext = WicketFormUtils.resolveInstance(getFence()).orElse(null); final String labelPath = StringUtils.defaultString( WicketFormUtils.generateTitlePath(getFence(), parentContext, message.getReporter(), instance), SFormUtil.generatePath(instance, it -> it == parentContext)); label.setDefaultModelObject(labelPath + " : " + bfm.getMessage()); } } return component; } }