Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-20945

Display macro fails to execute when no reference is specified

Details

    • Bug
    • Resolution: Unresolved
    • Major
    • None
    • 3.4-milestone-1
    • Rendering
    • None
    • Unknown
    • Awaiting Committer feedback

    Description

      To reproduce:

      1. Open the Macro Insertion dialog. (Other Macros)
      2. Find the Display macro in the list, and select it.
      3. Leave the reference page field empty and click Submit.

      I think setting the reference page field should be marked as mandatory to prevent this.

      Attachments

        Issue Links

          Activity

            [XWIKI-20945] Display macro fails to execute when no reference is specified
            mflorea Marius Dumitru Florea added a comment - - edited

            BTW what do we display when the field is not set and marked as mandatory?

            If you're referring to the WYSIWYG editor then it prevents you from inserting the macro and it focuses and highlights the mandatory field.

            On the macro rendering side there should be no difference: we already consider the reference to be mandatory, it's just that it's not marked as such in the macro descriptor.

            mflorea Marius Dumitru Florea added a comment - - edited BTW what do we display when the field is not set and marked as mandatory? If you're referring to the WYSIWYG editor then it prevents you from inserting the macro and it focuses and highlights the mandatory field. On the macro rendering side there should be no difference: we already consider the reference to be mandatory, it's just that it's not marked as such in the macro descriptor.
            vmassol Vincent Massol added a comment -

            BTW what do we display when the field is not set and marked as mandatory?

            vmassol Vincent Massol added a comment - BTW what do we display when the field is not set and marked as mandatory?
            mleduc Manuel Leduc added a comment - https://github.com/xwiki/xwiki-platform/pull/2232

            People

              Unassigned Unassigned
              douakli Dorian Ouakli
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated: