Class WysiwygInlineEditionHandler

  • All Implemented Interfaces:
    JcmsConstants, JaliosConstants

    public class WysiwygInlineEditionHandler
    extends JcmsFormHandler
    Java bean providing processing of for inline edition of wysiwyg fields.

    See WysiwygTag and jcore/wysiwyg/wysiwygInline.jsp.

    Since:
    jcms-10.0.0
    • Field Detail

      • IS_WYSIWYG_INLINE

        public static final java.lang.String IS_WYSIWYG_INLINE
        Name of Boolean attribute added to the current request to indicate the request is a wysiwyg inline call (edition or rendering).
        Since:
        jcms-10.0.3 / JCMS-7627
        See Also:
        Constant Field Values
    • Constructor Detail

      • WysiwygInlineEditionHandler

        public WysiwygInlineEditionHandler()
    • Method Detail

      • processAction

        public boolean processAction()
                              throws java.io.IOException
        Description copied from class: JcmsFormHandler
        Method to be implemented to check/validate action to be performed and process them.

        Default implementation is to return false. No need to call super method.

        This method may NOT be invoked at all if security validation are not met.

        You must ensure your handler and JSP can work properly without any code invoked in this method.

        Overrides:
        processAction in class JcmsFormHandler
        Returns:
        false if no redirection is needed, true otherwise
        Throws:
        java.io.IOException - IO Exception
      • validateInlineEdition

        public boolean validateInlineEdition()
      • getEditHandlerPath

        public java.lang.String getEditHandlerPath()
      • setId

        public void setId​(java.lang.String id)
      • setField

        public void setField​(java.lang.String field)
      • getField

        public java.lang.String getField()
      • getScrollTo

        public java.lang.String getScrollTo()
      • setScrollTo

        public void setScrollTo​(java.lang.String scrollTo)
      • canEditField

        public static boolean canEditField​(Data data,
                                           java.lang.String fieldName,
                                           Member loggedMember)
        Check if the specified member can edit the specified field of the specified data.

        All parameters are required to grant edition.
        Authorization is be refused if null or empty values are specified.

        Parameters:
        data - the Data to edit
        fieldName - the name of the field to edit as specified in type xml
        loggedMember - the Member for which inline edition action is being verified
        Returns:
        true if member is authorized, false otherwise