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

Enum displayer cannot be used on wiki macro parameter

    XMLWordPrintable

Details

    • Unknown
    • N/A
    • N/A

    Description

      Reproduction step:

      • Create a wiki macro with a parameter whom type is an enum
      • Try to use that macro in a document

      Expected result:

      • a select is created when using the macro with the enum values

      Obtained result:

      • a select is created but without any value in it and the following warning appears:
        2020-05-13 14:09:04,201 [http://localhost:8080/xwiki/bin/get/CKEditor/MacroService?outputSyntax=plain&language=en&data=descriptor&macroId=test1%2Fxwiki%2F2.1] WARN  o.x.v.i.DefaultVelocityEngine  - Cannot retrieve method getEnumConstants from object of class java.lang.Class due to security restrictions. 
        2020-05-13 14:09:04,202 [http://localhost:8080/xwiki/bin/get/CKEditor/MacroService?outputSyntax=plain&language=en&data=descriptor&macroId=test1%2Fxwiki%2F2.1] WARN  o.x.v.i.DefaultVelocityEngine  - Cannot retrieve method getEnumConstants from object of class java.lang.Class due to security restrictions. 
        

      Note: in order to ease the reproduction, you can directly import the attached XAR and try to use the macro "test1".

      Attachments

        Issue Links

          Activity

            People

              mleduc Manuel Leduc
              surli Simon Urli
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: