Class MessageTemplatesFragment

java.lang.Object
com.vaadin.flow.component.Component
com.vaadin.flow.component.Composite<T>
io.jmix.flowui.fragment.Fragment<JmixFormLayout>
io.jmix.notificationsflowui.fragment.MessageTemplatesFragment
All Implemented Interfaces:
com.vaadin.flow.component.AttachNotifier, com.vaadin.flow.component.DetachNotifier, com.vaadin.flow.component.HasElement, com.vaadin.flow.component.HasStyle, com.vaadin.flow.component.HasValidation, com.vaadin.flow.component.shared.HasValidationProperties, SupportsValidation<MessageTemplate>, FragmentOwner, Serializable

public class MessageTemplatesFragment extends Fragment<JmixFormLayout> implements SupportsValidation<MessageTemplate>
See Also:
  • Field Details

  • Constructor Details

    • MessageTemplatesFragment

      public MessageTemplatesFragment()
  • Method Details

    • onReady

      @Subscribe public void onReady(Fragment.ReadyEvent event)
    • onUseMessageTemplatesCheckboxComponentValueChange

      @Subscribe("useMessageTemplatesCheckbox") public void onUseMessageTemplatesCheckboxComponentValueChange(com.vaadin.flow.component.AbstractField.ComponentValueChangeEvent<JmixCheckbox,Boolean> event)
    • onMessageTemplatePickerValueChange

      @Subscribe("messageTemplatePicker") public void onMessageTemplatePickerValueChange(com.vaadin.flow.component.AbstractField.ComponentValueChangeEvent<EntityPicker<MessageTemplate>,MessageTemplate> event)
    • parametersDialogConfigurer

      protected void parametersDialogConfigurer(MessageTemplateParametersInputDialog view)
    • parametersDialogResultHandler

      protected void parametersDialogResultHandler(DialogWindow.AfterCloseEvent<MessageTemplateParametersInputDialog> event)
    • messageTemplatePickerLookupActionViewConfigurer

      @Install(to="messageTemplatePicker.lookupAction", subject="viewConfigurer") public void messageTemplatePickerLookupActionViewConfigurer(MessageTemplateListView view)
    • setDefaultBodyFieldVisionChangeCallback

      public void setDefaultBodyFieldVisionChangeCallback(Consumer<Boolean> defaultBodyFieldVisionChangeCallback)
    • setContentTypeProvider

      public void setContentTypeProvider(Supplier<ContentType> contentTypeProvider)
    • isMessageTemplateUsed

      public boolean isMessageTemplateUsed()
    • getMessageTemplate

      public MessageTemplate getMessageTemplate()
    • getParameters

      public Map<String,Object> getParameters()
    • createPramEditAction

      protected Action createPramEditAction()
    • onEditParamsAction

      protected void onEditParamsAction(ActionPerformedEvent event)
    • addValidator

      public com.vaadin.flow.shared.Registration addValidator(Validator<? super MessageTemplate> validator)
      Description copied from interface: SupportsValidation
      Adds a validator to the list of validators for the component. The provided validator will be used to validate the value of the component during validation execution.
      Specified by:
      addValidator in interface SupportsValidation<MessageTemplate>
      Parameters:
      validator - the validator to be added; should not be null
      Returns:
      a Registration object that allows removing the added validator
    • executeValidators

      public void executeValidators() throws ValidationException
      Description copied from interface: SupportsValidation
      Executes all registered validators against the current value of the component. If any of the validators fail, a ValidationException is thrown to indicate the failure. The exact behavior and order of validation depend on the validators added.
      Specified by:
      executeValidators in interface SupportsValidation<MessageTemplate>
      Throws:
      ValidationException - if validation fails for one or more validators
    • setInvalid

      public void setInvalid(boolean invalid)
      Description copied from interface: SupportsValidation
      Sets invalid state to the field considering result of field validation.
      • Invalid - false and validation passed - false = field is invalid
      • Invalid - false and validation passed - true = field is valid
      • Invalid - true and validation passed - false = field is invalid
      • Invalid - true and validation passed - true = field is invalid
      Specified by:
      setInvalid in interface com.vaadin.flow.component.HasValidation
      Specified by:
      setInvalid in interface com.vaadin.flow.component.shared.HasValidationProperties
      Specified by:
      setInvalid in interface SupportsValidation<MessageTemplate>
      Parameters:
      invalid - whether field should be invalid